Skip to content

Commit

Permalink
Merge pull request #314 from wakmusic/fix/add_playlist
Browse files Browse the repository at this point in the history
  • Loading branch information
youn9k authored Jun 4, 2023
2 parents a025da2 + b370f41 commit fbf9328
Showing 1 changed file with 6 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,12 @@ public extension PlayState {
}
self.playList.append(notDuplicatedSongs)

if self.state == .unstarted { self.switchPlayerMode(to: .mini) }

self.currentSong = self.playList.currentPlaySong
if let currentSong {
self.player.cue(source: .video(id: currentSong.id))
if self.state == .unstarted {
self.switchPlayerMode(to: .mini)
self.currentSong = self.playList.currentPlaySong
if let currentSong = currentSong {
self.player.cue(source: .video(id: currentSong.id))
}
}
}
}

0 comments on commit fbf9328

Please sign in to comment.