diff options
author | Jason A. Donenfeld <Jason@zx2c4.com> | 2018-07-08 23:59:25 +0200 |
---|---|---|
committer | Jason A. Donenfeld <Jason@zx2c4.com> | 2018-07-08 23:59:25 +0200 |
commit | d50e0f5fb9d60992d65a818a8af1cc20e878e312 (patch) | |
tree | 51770336860a381739173e754123bd4c111e8cd6 /app/src/main/java/com/wireguard/android/BootShutdownReceiver.java | |
parent | c696e9f2755e236afffffd1135e01c51cc25682b (diff) |
Use instanceOf instead of getClass
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'app/src/main/java/com/wireguard/android/BootShutdownReceiver.java')
-rw-r--r-- | app/src/main/java/com/wireguard/android/BootShutdownReceiver.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/src/main/java/com/wireguard/android/BootShutdownReceiver.java b/app/src/main/java/com/wireguard/android/BootShutdownReceiver.java index 1a8c96a0..3b9f852d 100644 --- a/app/src/main/java/com/wireguard/android/BootShutdownReceiver.java +++ b/app/src/main/java/com/wireguard/android/BootShutdownReceiver.java @@ -21,7 +21,7 @@ public class BootShutdownReceiver extends BroadcastReceiver { @Override public void onReceive(final Context context, final Intent intent) { Application.onHaveBackend(backend -> { - if (backend.getClass() != WgQuickBackend.class) + if (!(backend instanceof WgQuickBackend)) return; final String action = intent.getAction(); if (action == null) |