@@ -195,7 +195,6 @@ export default {
195195 if (! this .musicInfo .songmid ) return
196196 console .log (' 出错' )
197197 this .stopPlay ()
198- this .sendProgressEvent (this .progress , ' error' )
199198 if (this .audio .error .code !== 1 && this .retryNum < 3 ) { // 若音频URL无效则尝试刷新3次URL
200199 // console.log(this.retryNum)
201200 this .audioErrorTime = this .audio .currentTime // 记录出错的播放时间
@@ -205,21 +204,7 @@ export default {
205204 return
206205 }
207206
208- // let urls = this.player_info.targetSong.urls
209- // if (urls && urls.some((url, index) => {
210- // if (this.musicInfo.musicUrl.includes(url)) {
211- // let newUrl = urls[index + 1]
212- // if (!newUrl) return false
213- // this.musicInfo.musicUrl = this.musicInfo.musicUrl.replace(url, newUrl)
214- // // this.musicInfo.musicUrl = newUrl ? this.musicInfo.musicUrl.replace(url, newUrl) : this.setFormTag(this.musicInfo.musicUrl.replace(url, urls[0]))
215- // return true
216- // }
217- // })) {
218- // this.audio.src = this.musicInfo.musicUrl
219- // // console.log(this.musicInfo.musicUrl)
220- // } else {
221- // this.handleNext()
222- // }
207+ this .sendProgressEvent (this .progress , ' error' )
223208 this .status = ' 音频加载出错,5 秒后切换下一首'
224209 this .addDelayNextTimeout ()
225210 })
@@ -416,12 +401,12 @@ export default {
416401 }
417402 },
418403 setLrc (targetSong ) {
419- this .musicInfo .lrc = targetSong .lyric
404+ this .musicInfo .lrc = targetSong .lrc
420405
421406 let lrcP = this .musicInfo .lrc
422407 ? Promise .resolve ()
423408 : this .getLrc (targetSong).then (() => {
424- this .musicInfo .lrc = targetSong .lyric
409+ this .musicInfo .lrc = targetSong .lrc
425410 })
426411
427412 lrcP
0 commit comments