移除kg源的歌词文件开头的空白字符串

This commit is contained in:
lyswhut
2020-11-02 15:13:09 +08:00
parent 897107ca23
commit 5c96c83f98
4 changed files with 20 additions and 26 deletions
+1
View File
@@ -3,6 +3,7 @@ import { decodeLyric } from './util'
const parseLyric = str => {
str = str.replace(/(?:<\d+,\d+,\d+>|\r)/g, '')
if (str.startsWith('\ufeff[id:$00000000]')) str = str.replace('\ufeff[id:$00000000]\n', '')
let trans = str.match(/\[language:([\w=\\/+]+)\]/)
let tlyric
if (trans) {