Exclude some more app state preferences from backups
(cherry picked from commit bcc42dd259cd528641ae4963b9b6ef290332bb27) # Conflicts: # app/build.gradle.kts
This commit is contained in:
parent
e47941ae70
commit
27c7154cdb
@ -52,7 +52,7 @@ object Migrations {
|
||||
backupPreferences: BackupPreferences,
|
||||
trackerManager: TrackerManager,
|
||||
): Boolean {
|
||||
val lastVersionCode = preferenceStore.getInt("last_version_code", 0)
|
||||
val lastVersionCode = preferenceStore.getInt(Preference.appStateKey("last_version_code"), 0)
|
||||
val oldVersion = lastVersionCode.get()
|
||||
if (oldVersion < BuildConfig.VERSION_CODE) {
|
||||
lastVersionCode.set(BuildConfig.VERSION_CODE)
|
||||
@ -399,7 +399,7 @@ object Migrations {
|
||||
newKey = { Preference.privateKey(it) },
|
||||
)
|
||||
}
|
||||
if (oldVersion < 108) {
|
||||
if (oldVersion < 110) {
|
||||
val prefsToReplace = listOf(
|
||||
"pref_download_only",
|
||||
"incognito_mode",
|
||||
@ -409,6 +409,9 @@ object Migrations {
|
||||
"library_update_last_timestamp",
|
||||
"library_unseen_updates_count",
|
||||
"last_used_category",
|
||||
"last_app_check",
|
||||
"last_ext_check",
|
||||
"last_version_code",
|
||||
)
|
||||
replacePreferences(
|
||||
preferenceStore = preferenceStore,
|
||||
|
@ -31,7 +31,7 @@ internal class ExtensionGithubApi {
|
||||
private val json: Json by injectLazy()
|
||||
|
||||
private val lastExtCheck: Preference<Long> by lazy {
|
||||
preferenceStore.getLong("last_ext_check", 0)
|
||||
preferenceStore.getLong(Preference.appStateKey("last_ext_check"), 0)
|
||||
}
|
||||
|
||||
// SY -->
|
||||
|
@ -623,7 +623,8 @@ object EXHMigrations {
|
||||
preferenceStore.getString(key).delete()
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
if (oldVersion under 59) {
|
||||
val prefsToReplace = listOf(
|
||||
"pref_download_only",
|
||||
"incognito_mode",
|
||||
@ -633,6 +634,9 @@ object EXHMigrations {
|
||||
"library_update_last_timestamp",
|
||||
"library_unseen_updates_count",
|
||||
"last_used_category",
|
||||
"last_app_check",
|
||||
"last_ext_check",
|
||||
"last_version_code",
|
||||
"skip_pre_migration",
|
||||
"eh_auto_update_stats",
|
||||
)
|
||||
|
@ -13,7 +13,7 @@ class GetApplicationRelease(
|
||||
) {
|
||||
|
||||
private val lastChecked: Preference<Long> by lazy {
|
||||
preferenceStore.getLong("last_app_check", 0)
|
||||
preferenceStore.getLong(Preference.appStateKey("last_app_check"), 0)
|
||||
}
|
||||
|
||||
suspend fun await(arguments: Arguments): Result {
|
||||
|
Loading…
x
Reference in New Issue
Block a user