mirror of
https://github.com/KRTirtho/spotube.git
synced 2026-09-20 06:34:00 +00:00
fix(plugin): handle service closure exception during authentication check
This commit is contained in:
parent
0a76abba65
commit
11cc5e2457
@ -676,7 +676,7 @@ fun PluginScreen(
|
|||||||
val service =
|
val service =
|
||||||
selectedService ?: return@LaunchedEffect
|
selectedService ?: return@LaunchedEffect
|
||||||
|
|
||||||
|
try {
|
||||||
service.use {
|
service.use {
|
||||||
val pluginRequiresAuth =
|
val pluginRequiresAuth =
|
||||||
coreAPI.requiresAuthentication
|
coreAPI.requiresAuthentication
|
||||||
@ -687,6 +687,10 @@ fun PluginScreen(
|
|||||||
isLoggedIn = loggedIn
|
isLoggedIn = loggedIn
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
} catch (_: Exception) {
|
||||||
|
// Service may have been stopped/closed
|
||||||
|
// concurrently when the plugin selection changed
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
val logoPath = remember(plugin.id) {
|
val logoPath = remember(plugin.id) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user