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

This commit is contained in:
Horis
2025-06-01 23:23:14 +08:00
committed by HapeLee
parent 91c8fa2d6c
commit 459aba41e2
@@ -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()
}
}