mirror of
https://github.com/revanced/revanced-integrations.git
synced 2025-01-07 10:35:49 +01:00
fix(youtube): save new instead of default value (#298)
This commit is contained in:
parent
737246636b
commit
559bbf9778
@ -343,19 +343,19 @@ public enum SettingsEnum {
|
|||||||
|
|
||||||
switch (getReturnType()) {
|
switch (getReturnType()) {
|
||||||
case FLOAT:
|
case FLOAT:
|
||||||
SharedPrefHelper.saveFloat(sharedPref, path, (float) defaultValue);
|
SharedPrefHelper.saveFloat(sharedPref, path, (float) newValue);
|
||||||
break;
|
break;
|
||||||
case LONG:
|
case LONG:
|
||||||
SharedPrefHelper.saveLong(sharedPref, path, (long) defaultValue);
|
SharedPrefHelper.saveLong(sharedPref, path, (long) newValue);
|
||||||
break;
|
break;
|
||||||
case BOOLEAN:
|
case BOOLEAN:
|
||||||
SharedPrefHelper.saveBoolean(sharedPref, path, (boolean) newValue);
|
SharedPrefHelper.saveBoolean(sharedPref, path, (boolean) newValue);
|
||||||
break;
|
break;
|
||||||
case INTEGER:
|
case INTEGER:
|
||||||
SharedPrefHelper.saveInt(sharedPref, path, (int) defaultValue);
|
SharedPrefHelper.saveInt(sharedPref, path, (int) newValue);
|
||||||
break;
|
break;
|
||||||
case STRING:
|
case STRING:
|
||||||
SharedPrefHelper.saveString(sharedPref, path, (String) defaultValue);
|
SharedPrefHelper.saveString(sharedPref, path, (String) newValue);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
LogHelper.printException(() -> ("Setting does not have a valid Type. Name is: " + name()));
|
LogHelper.printException(() -> ("Setting does not have a valid Type. Name is: " + name()));
|
||||||
|
Loading…
Reference in New Issue
Block a user