mirror of
				https://github.com/mihonapp/mihon.git
				synced 2025-10-30 22:07:57 +01:00 
			
		
		
		
	Remove redundant DB call in library settings (closes #3128)
(cherry picked from commit 521ebf0678)
# Conflicts:
#	app/src/main/java/eu/kanade/tachiyomi/data/backup/BackupRestoreService.kt
			
			
This commit is contained in:
		| @@ -235,6 +235,10 @@ class BackupRestoreService : Service() { | ||||
|  | ||||
|         // Restore individual manga | ||||
|         mangasJson.forEach { | ||||
|             if (job?.isActive != true) { | ||||
|                 throw Exception(getString(R.string.restoring_backup_canceled)) | ||||
|             } | ||||
|  | ||||
|             restoreManga(it.asJsonObject) | ||||
|         } | ||||
|  | ||||
| @@ -275,10 +279,6 @@ class BackupRestoreService : Service() { | ||||
|                     ?: JsonArray() | ||||
|             ) | ||||
|  | ||||
|             if (job?.isActive != true) { | ||||
|                 throw Exception(getString(R.string.restoring_backup_canceled)) | ||||
|             } | ||||
|  | ||||
|             // EXH --> | ||||
|             manga = EXHMigrations.migrateBackupEntry(manga) | ||||
|             // <-- EXH | ||||
|   | ||||
| @@ -172,7 +172,7 @@ class SettingsLibraryController : SettingsController() { | ||||
|             preference { | ||||
|                 titleRes = R.string.action_edit_categories | ||||
|  | ||||
|                 val catCount = db.getCategories().executeAsBlocking().size | ||||
|                 val catCount = dbCategories.size | ||||
|                 summary = context.resources.getQuantityString(R.plurals.num_categories, catCount, catCount) | ||||
|  | ||||
|                 onClick { | ||||
|   | ||||
		Reference in New Issue
	
	Block a user