MoePlayer/cPlayer

播放纯音乐时碰到错误 (歌词解析)

a632079 opened this issue · 5 comments

错误信息 (Firefox 58):

TypeError: n is undefined                                      at view.ts:360:32

(Chrome 65)

view.ts:361 Uncaught TypeError: Cannot read property 'time' of undefined
    at t.value (view.ts:361)
    at t.r.handleOpenAudio (view.ts:393)
    at t.n.emit (events.js:81)
    at t.value (index.ts:160)
    at t.value (index.ts:214)
    at t.r.handleClickPlayList (view.ts:377)
    at HTMLLIElement.<anonymous> (view.ts:312)

URL: https://cdn.a632079.me/163cplayer.html?playlist=28391863,22640061,32317208,28891491,477839635,427610054,463722628,436668247,5307982,394912,394911,857896,347230,115502,28949444,109558,185879&autoplay=true
使用接口: https://api.a632079.me/nm/summary/28391863,22640061,32317208,28891491,477839635,427610054,463722628,436668247,5307982,394912,394911,857896,347230,115502,28949444,109558,185879?lyric=true
无歌词的歌曲,我是这样定义的(似乎没毛病):

{
base : "[00:00.00]纯音乐,敬请聆听。\n"
}

根据初步调试,感觉可能和歌词有关。希望大大能够给个提示。

@Copay
已经找到问题解决方案

  • 原因: 歌词解析需要两个以上的时间
    • 错误: [00.00.000] 01\n
    • 成功: [00.00.000] 01\n[00.01.000]02
      建议在相关函数内添加检测.....
Copay commented

纯音乐不要加歌词!

EYHN commented

为什么我没法复现呢