fix race condition on exit: disable UI playback state callbacks

This commit is contained in:
Drew Weymouth
2023-04-06 19:17:06 -07:00
parent f7b381c22c
commit 565c9e98a4
2 changed files with 15 additions and 1 deletions
+2 -1
View File
@@ -151,7 +151,8 @@ func (a *App) LoginToDefaultServer(string) error {
}
func (a *App) Shutdown() {
a.Player.Stop()
a.PlaybackManager.DisableCallbacks()
a.Player.Stop() // will trigger scrobble check
a.Config.LocalPlayback.Volume = a.Player.GetVolume()
a.cancel()
a.Player.Destroy()