fix(player): fix can't read prop seek of null (#537)

fix #488 fix #497
This commit is contained in:
Map1en_ 2021-04-12 01:16:28 +08:00 committed by GitHub
parent 5cf0092b4f
commit 872fd73b05
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -247,7 +247,7 @@ export default class {
autoplay = true,
ifUnplayableThen = "playNextTrack"
) {
if (autoplay) this._scrobble(this.currentTrack, this._howler.seek(), true);
if (autoplay) this._scrobble(this.currentTrack, this._howler?.seek(), true);
return getTrackDetail(id).then((data) => {
let track = data.songs[0];
this._currentTrack = track;