In a PlaylistNext() handler pass a current song as a copy.
This commit is contained in:
parent
f53f30963d
commit
07b0199193
@ -65,7 +65,7 @@ func (dj *DJHandlers) PlaylistNext(w http.ResponseWriter, _ *http.Request) {
|
||||
Duration: oggf.GetDuration(),
|
||||
MaxListeners: dj.listeners.Current(),
|
||||
StartAt: time.Now()}
|
||||
radio.CheckAndUpdateMostListenedSong(dj.songList.Current())
|
||||
radio.CheckAndUpdateMostListenedSong(*dj.songList.Current())
|
||||
dj.songList.Add(song)
|
||||
}()
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user