Skip to content

Commit

Permalink
Fix shake threshold not initialized to default on first launch
Browse files Browse the repository at this point in the history
Regression: ff53685
  • Loading branch information
pilot51 committed Dec 4, 2024
1 parent 88302b4 commit 1b10d12
Showing 1 changed file with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,14 @@ object PreferenceHelper {
} else {
spFile.delete()
}
} else settingsDao.insert(Settings.defaults)
} else {
settingsDao.insert(Settings.defaults)
dataStore.edit { prefs ->
prefs[KEY_SHAKE_THRESHOLD] = DEFAULT_SHAKE_THRESHOLD
prefs[KEY_APP_DEFAULT_ENABLE] = DEFAULT_APP_DEFAULT_ENABLE
prefs[KEY_IS_SUSPENDED] = DEFAULT_IS_SUSPENDED
}
}
}

fun exportBackup(uri: Uri) {
Expand Down

0 comments on commit 1b10d12

Please sign in to comment.