From 655720fc05a8038d7b4e8232082bf9b1c84c5e90 Mon Sep 17 00:00:00 2001 From: Damontecres Date: Thu, 13 Nov 2025 11:52:52 -0500 Subject: [PATCH] Small fix for deleting current server or user --- .../com/github/damontecres/wholphin/data/ServerRepository.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/com/github/damontecres/wholphin/data/ServerRepository.kt b/app/src/main/java/com/github/damontecres/wholphin/data/ServerRepository.kt index f16f9aab..490ad701 100644 --- a/app/src/main/java/com/github/damontecres/wholphin/data/ServerRepository.kt +++ b/app/src/main/java/com/github/damontecres/wholphin/data/ServerRepository.kt @@ -174,7 +174,7 @@ class ServerRepository } suspend fun removeUser(user: JellyfinUser) { - if (currentUser == user) { + if (currentUser.value?.id == user.id) { withContext(Dispatchers.Main) { _current.value = null } @@ -193,7 +193,7 @@ class ServerRepository } suspend fun removeServer(server: JellyfinServer) { - if (currentServer == server) { + if (currentServer.value?.id == server.id) { withContext(Dispatchers.Main) { _current.value = null }