After performing the removal in CacheBookService, remove the corresponding item from cacheBookMap. #5090

This commit is contained in:
Horis authored and HapeLee committed 2025-06-01 23:23:14 +08:00
1 parent 91c8fa2d6c
commit 459aba41e2
1 file changed
+5 -1
@@ -85,7 +85,11 @@ class CacheBookService : BaseService() {
intent.getIntExtra("end", 0)
)
IntentAction.remove -> removeDownload(intent.getStringExtra("bookUrl"))
IntentAction.remove -> {
val bookUrl = intent.getStringExtra("bookUrl")
CacheBook.cacheBookMap[bookUrl]?.stop()
CacheBook.cacheBookMap.remove(bookUrl)
}
IntentAction.stop -> stopSelf()
}
}