Skip to content

Fix (PreferenceRestorer): correctly backup/restore preferences related to categories#1726

Merged
AntsyLich merged 10 commits intomihonapp:mainfrom
cuong-tran:backup-restore-category-pref
Feb 24, 2025
Merged

Fix (PreferenceRestorer): correctly backup/restore preferences related to categories#1726
AntsyLich merged 10 commits intomihonapp:mainfrom
cuong-tran:backup-restore-category-pref

Conversation

@cuong-tran
Copy link
Copy Markdown
Contributor

Preferences related to category:

  • Library/Default category
  • Library/Global update categories
  • Downloads/Excluded categoreis
  • Downloads/Auto-download categories

They are being stored in preferences as category ID and hence failed to be backed up/restored correctly.

@AntsyLich
Copy link
Copy Markdown
Member

Maybe we should also keep the category id when making backup and set this preferences accordingly?

@cuong-tran
Copy link
Copy Markdown
Contributor Author

Maybe we should also keep the category id when making backup and set this preferences accordingly?

That would be better comparing to using order as currently. Although order is being used to distinguish category in the backup but since we don't have unique field, order might be duplicated.
The only downside is need changing backup schema.

@AntsyLich
Copy link
Copy Markdown
Member

The only downside is need changing backup schema.
Older backups wouldn't have worked correctly anyway

@cuong-tran cuong-tran force-pushed the backup-restore-category-pref branch from 8684da2 to 14a1ef2 Compare February 16, 2025 09:50
Comment thread app/src/main/java/eu/kanade/tachiyomi/data/backup/models/BackupCategory.kt Outdated
@cuong-tran cuong-tran force-pushed the backup-restore-category-pref branch from 14a1ef2 to ce760fc Compare February 23, 2025 19:17
@AntsyLich AntsyLich enabled auto-merge (squash) February 24, 2025 21:56
@AntsyLich AntsyLich merged commit e1724d1 into mihonapp:main Feb 24, 2025
@cuong-tran cuong-tran deleted the backup-restore-category-pref branch February 25, 2025 09:59
cuong-tran added a commit to komikku-app/komikku that referenced this pull request Feb 25, 2025
Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
(cherry picked from commit e1724d1)
cuong-tran added a commit to komikku-app/komikku that referenced this pull request Feb 26, 2025
… preferences (mihonapp/mihon#1726)

Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
(cherry picked from commit e1724d1)
@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Feb 28, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants