diff --git a/wakelock_plus/android/src/main/kotlin/dev/fluttercommunity/plus/wakelock/Wakelock.kt b/wakelock_plus/android/src/main/kotlin/dev/fluttercommunity/plus/wakelock/Wakelock.kt index 8ba445a..bdc360d 100644 --- a/wakelock_plus/android/src/main/kotlin/dev/fluttercommunity/plus/wakelock/Wakelock.kt +++ b/wakelock_plus/android/src/main/kotlin/dev/fluttercommunity/plus/wakelock/Wakelock.kt @@ -29,7 +29,7 @@ internal class Wakelock { fun isEnabled(): IsEnabledMessage { if (activity == null) { - throw NoActivityException() + return IsEnabledMessage(enabled = false) } return IsEnabledMessage(enabled = enabled)