Also apply changes to online restore

This commit is contained in:
Jobobby04 2020-10-14 13:15:54 -04:00
parent f91d1af373
commit e7c16cd0d1

View File

@ -451,13 +451,12 @@ class FullBackupManager(val context: Context) : AbstractBackupManager() {
return false
}
for (chapter in chapters) {
val pos = dbChapters.indexOf(chapter)
chapters.forEach { chapter ->
val pos = dbChapters.indexOfFirst { it.url == chapter.url }
if (pos != -1) {
val dbChapter = dbChapters[pos]
chapter.id = dbChapter.id
chapter.copyFrom(dbChapter)
break
}
}
// Filter the chapters that couldn't be found.