mirror of
https://github.com/revanced/revanced-integrations.git
synced 2025-01-21 01:07:32 +01:00
chore: use correct exception
This commit is contained in:
parent
cf74fbd6fd
commit
2af3911395
@ -12,8 +12,6 @@ import app.revanced.integrations.shared.Utils;
|
||||
import app.revanced.integrations.shared.settings.BooleanSetting;
|
||||
import app.revanced.integrations.shared.settings.Setting;
|
||||
|
||||
import java.security.InvalidParameterException;
|
||||
|
||||
import static app.revanced.integrations.shared.StringRef.str;
|
||||
|
||||
/**
|
||||
@ -150,7 +148,7 @@ public abstract class AbstractPreferenceFragment extends PreferenceFragment {
|
||||
protected void updatePreference(@NonNull Preference pref, @NonNull Setting<?> setting,
|
||||
boolean syncSetting, boolean applySettingToPreference) {
|
||||
if (!syncSetting && applySettingToPreference) {
|
||||
throw new InvalidParameterException();
|
||||
throw new IllegalArgumentException();
|
||||
}
|
||||
if (syncSetting) {
|
||||
if (pref instanceof SwitchPreference) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user