mirror of
https://github.com/M66B/FairEmail.git
synced 2025-03-01 17:26:12 +00:00
Backup: fixed version
This commit is contained in:
parent
b68348571f
commit
41e1864367
1 changed files with 2 additions and 1 deletions
|
@ -72,6 +72,7 @@ public class FairEmailBackupAgent extends BackupAgent {
|
|||
return;
|
||||
|
||||
JSONObject jroot = new JSONObject();
|
||||
jroot.put("version", 1);
|
||||
|
||||
JSONObject jsettings = new JSONObject();
|
||||
jsettings.put("enabled", prefs.getBoolean("enabled", true));
|
||||
|
@ -174,7 +175,7 @@ public class FairEmailBackupAgent extends BackupAgent {
|
|||
EntityLog.log(this, "Restore decompressed=" + dataBuf.length);
|
||||
|
||||
JSONObject jroot = new JSONObject(new String(dataBuf, StandardCharsets.UTF_8));
|
||||
jroot.put("version", 1);
|
||||
EntityLog.log(this, "Restore version=" + jroot.optInt("version", 0));
|
||||
|
||||
SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(this);
|
||||
SharedPreferences.Editor editor = prefs.edit();
|
||||
|
|
Loading…
Reference in a new issue