diff --git a/server/src/client/music/MusicClient.cpp b/server/src/client/music/MusicClient.cpp index 07e1eee..3a8ed8f 100644 --- a/server/src/client/music/MusicClient.cpp +++ b/server/src/client/music/MusicClient.cpp @@ -215,6 +215,8 @@ void MusicClient::notifySongChange(const std::shared_ptr& song) } void MusicClient::handle_event_song_ended() { + auto playlist = this->playlist(); + if(playlist) playlist->next(); this->replay_next_song(); } @@ -223,6 +225,8 @@ void MusicClient::handle_event_song_dry() { } void MusicClient::handle_event_song_replay_failed() { + auto playlist = this->playlist(); + if(playlist) playlist->next(); this->replay_next_song(); } @@ -234,5 +238,6 @@ void MusicClient::replay_next_song() { this->replay_song(song); else if(!await_load) playlist->next(); - } + } else + this->replay_song(nullptr); } \ No newline at end of file