clear discord rpc on player stop (#2239)

This commit is contained in:
jeffvli
2026-07-18 21:16:51 -07:00
parent a2ee9b9059
commit d960603268
@@ -100,13 +100,14 @@ export const useDiscordRpc = () => {
if ( if (
!hasTrackOrRadio || // No track and not playing radio !hasTrackOrRadio || // No track and not playing radio
(current[2] === 'paused' && !discordSettings.showPaused) // Paused with show paused setting disabled current[2] === PlayerStatus.STOPPED || // Stopped (stop button or queue end)
(current[2] === PlayerStatus.PAUSED && !discordSettings.showPaused) // Paused with show paused setting disabled
) { ) {
let reason: string; let reason: string;
if (!hasTrackOrRadio) { if (!hasTrackOrRadio) {
reason = current[0] ? 'no_track' : 'no_track_or_radio'; reason = current[0] ? 'no_track' : 'no_track_or_radio';
} else if (current[1] === 0 && !isPlayingRadio) { } else if (current[2] === PlayerStatus.STOPPED) {
reason = 'start_of_track'; reason = 'stopped';
} else { } else {
reason = 'paused_with_show_paused_disabled'; reason = 'paused_with_show_paused_disabled';
} }