diff --git a/src/components/remoteControl/index.tsx b/src/components/remoteControl/index.tsx index eeaa62a..f50f28d 100644 --- a/src/components/remoteControl/index.tsx +++ b/src/components/remoteControl/index.tsx @@ -57,9 +57,7 @@ const RemoteControlDialog = () => { queryKey: ["remoteSessions"], queryFn: async () => { if (!api || !user?.Id) return []; - const result = await getSessionApi(api).getSessions({ - controllableByUserId: user.Id, - }); + const result = await getSessionApi(api).getSessions(); return result.data; }, enabled: open && !!api && !!user?.Id, @@ -128,11 +126,13 @@ const RemoteControlDialog = () => { }), }); + // Show all other sessions: some clients report SupportsRemoteControl=false + // even though they accept playstate commands, so do not hide them. const remoteSessions = (sessions.data ?? []).filter( (session) => session.Id && session.DeviceId !== api?.deviceInfo.id && - session.SupportsRemoteControl !== false, + session.UserId === user?.Id, ); const seek = (session: SessionInfoDto, offsetSeconds: number) => { @@ -189,7 +189,7 @@ const RemoteControlDialog = () => { const playState = session.PlayState; const duration = nowPlaying?.RunTimeTicks ?? 0; const position = playState?.PositionTicks ?? 0; - const supportsControl = session.SupportsRemoteControl !== false; + const supportsControl = true; return ( { queryKey: ["remoteSessions"], queryFn: async () => { if (!api || !user?.Id) return []; - const result = await getSessionApi(api).getSessions({ - controllableByUserId: user.Id, - }); + // Get every session: many Jellyfin clients don't report + // SupportsRemoteControl, so filtering by controllableByUserId hides + // devices that can still receive commands. + const result = await getSessionApi(api).getSessions(); return result.data; }, enabled: !!api && !!user?.Id, @@ -40,6 +41,7 @@ const RemotePlaybackBar = () => { (session: SessionInfoDto) => session.Id && session.DeviceId !== api?.deviceInfo.id && + session.UserId === user?.Id && session.NowPlayingItem, );