mirror of
https://github.com/sudoxnym/audiobookshelf-atv.git
synced 2026-04-15 12:06:57 +00:00
Android Auto: Prevent crashing loop in case that app restarts while browsing content
This commit is contained in:
parent
a08ae6f977
commit
8caa08843e
1 changed files with 6 additions and 0 deletions
|
|
@ -1042,6 +1042,12 @@ class PlayerNotificationService : MediaBrowserServiceCompat() {
|
|||
|
||||
result.detach()
|
||||
|
||||
// Prevent crashing if app is restarted while browsing
|
||||
if ((parentMediaId != DOWNLOADS_ROOT && parentMediaId != AUTO_MEDIA_ROOT) && !firstLoadDone){
|
||||
result.sendResult(null)
|
||||
return
|
||||
}
|
||||
|
||||
if (parentMediaId == DOWNLOADS_ROOT) { // Load downloads
|
||||
|
||||
val localBooks = DeviceManager.dbManager.getLocalLibraryItems("book")
|
||||
|
|
|
|||
Loading…
Reference in a new issue