diff --git a/android/src/main/java/com/gijoehosaphat/keepscreenon/KeepScreenOnModule.java b/android/src/main/java/com/gijoehosaphat/keepscreenon/KeepScreenOnModule.java index 8e0050b..32dddff 100644 --- a/android/src/main/java/com/gijoehosaphat/keepscreenon/KeepScreenOnModule.java +++ b/android/src/main/java/com/gijoehosaphat/keepscreenon/KeepScreenOnModule.java @@ -25,7 +25,7 @@ public String getName() { @ReactMethod public void setKeepScreenOn(Boolean bKeepScreenOn) { final Activity activity = getCurrentActivity(); - if (bKeepScreenOn == true) { + if (bKeepScreenOn) { if (activity != null) { activity.runOnUiThread(new Runnable() { @Override @@ -34,7 +34,7 @@ public void run() { } }); } - } else if (bKeepScreenOn == false) { + } else { if (activity != null) { activity.runOnUiThread(new Runnable() { @Override