|
|
@ -881,7 +881,13 @@ public class ActivitySetup extends ActivityBase implements FragmentManager.OnBac
|
|
|
|
for (int s = 0; s < jsettings.length(); s++) {
|
|
|
|
for (int s = 0; s < jsettings.length(); s++) {
|
|
|
|
JSONObject jsetting = (JSONObject) jsettings.get(s);
|
|
|
|
JSONObject jsetting = (JSONObject) jsettings.get(s);
|
|
|
|
String key = jsetting.getString("key");
|
|
|
|
String key = jsetting.getString("key");
|
|
|
|
if (!"pro".equals(key) || BuildConfig.DEBUG) {
|
|
|
|
|
|
|
|
|
|
|
|
if ("pro".equals(key) && !BuildConfig.DEBUG)
|
|
|
|
|
|
|
|
continue;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if ("biometrics".equals(key) && !Helper.canAuthenticate(context))
|
|
|
|
|
|
|
|
continue;
|
|
|
|
|
|
|
|
|
|
|
|
Object value = jsetting.get("value");
|
|
|
|
Object value = jsetting.get("value");
|
|
|
|
if (value instanceof Boolean)
|
|
|
|
if (value instanceof Boolean)
|
|
|
|
editor.putBoolean(key, (Boolean) value);
|
|
|
|
editor.putBoolean(key, (Boolean) value);
|
|
|
@ -893,9 +899,9 @@ public class ActivitySetup extends ActivityBase implements FragmentManager.OnBac
|
|
|
|
editor.putString(key, (String) value);
|
|
|
|
editor.putString(key, (String) value);
|
|
|
|
else
|
|
|
|
else
|
|
|
|
throw new IllegalArgumentException("Unknown settings type key=" + key);
|
|
|
|
throw new IllegalArgumentException("Unknown settings type key=" + key);
|
|
|
|
|
|
|
|
|
|
|
|
Log.i("Imported setting=" + key);
|
|
|
|
Log.i("Imported setting=" + key);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
editor.apply();
|
|
|
|
editor.apply();
|
|
|
|
ApplicationEx.upgrade(context);
|
|
|
|
ApplicationEx.upgrade(context);
|
|
|
|
|
|
|
|
|
|
|
|