summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--app/src/main/java/com/wireguard/android/util/FragmentUtils.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/src/main/java/com/wireguard/android/util/FragmentUtils.java b/app/src/main/java/com/wireguard/android/util/FragmentUtils.java
index a3e622b2..5fb9a3bc 100644
--- a/app/src/main/java/com/wireguard/android/util/FragmentUtils.java
+++ b/app/src/main/java/com/wireguard/android/util/FragmentUtils.java
@@ -18,8 +18,8 @@ public final class FragmentUtils {
public static SettingsActivity getPrefActivity(final Preference preference) {
final Context context = preference.getContext();
if (context instanceof ContextThemeWrapper) {
- if (((ContextThemeWrapper) context).getBaseContext() instanceof SettingsActivity) {
- return ((SettingsActivity) ((ContextThemeWrapper) context).getBaseContext());
+ if (context instanceof SettingsActivity) {
+ return ((SettingsActivity) context);
}
}
return null;