mirror of
https://github.com/libre-tube/LibreTube.git
synced 2025-01-07 10:00:31 +05:30
fix some backup stuff
This commit is contained in:
parent
373acbf8b9
commit
11fc6fd1f2
@ -50,13 +50,14 @@ class AdvancedSettings : MaterialPreferenceFragment() {
|
|||||||
val backupSettings = findPreference<Preference>(PreferenceKeys.BACKUP_SETTINGS)
|
val backupSettings = findPreference<Preference>(PreferenceKeys.BACKUP_SETTINGS)
|
||||||
backupSettings?.setOnPreferenceClickListener {
|
backupSettings?.setOnPreferenceClickListener {
|
||||||
createFile.launch("preferences.xml")
|
createFile.launch("preferences.xml")
|
||||||
activity?.recreate()
|
|
||||||
true
|
true
|
||||||
}
|
}
|
||||||
|
|
||||||
val restoreSettings = findPreference<Preference>(PreferenceKeys.RESTORE_SETTINGS)
|
val restoreSettings = findPreference<Preference>(PreferenceKeys.RESTORE_SETTINGS)
|
||||||
restoreSettings?.setOnPreferenceClickListener {
|
restoreSettings?.setOnPreferenceClickListener {
|
||||||
getContent.launch("*/*")
|
getContent.launch("*/*")
|
||||||
|
// reset the token
|
||||||
|
PreferenceHelper.setToken("")
|
||||||
activity?.recreate()
|
activity?.recreate()
|
||||||
true
|
true
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user