Skip to content

Commit

Permalink
fix variable
Browse files Browse the repository at this point in the history
  • Loading branch information
pmtkh committed Aug 16, 2022
1 parent d85abfa commit 1aff7e7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/android/com/adobe/phonegap/push/FullScreenActivity.kt
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ class FullScreenActivity : Activity() {
or WindowManager.LayoutParams.FLAG_ALLOW_LOCK_WHILE_SCREEN_ON
)
}
val candidate: KeyguardManager? = getSystemService(Context.KEYGUARD_SERVICE) as KeyguardManager?
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O && candidate != null) {
val keyguardManager: KeyguardManager? = getSystemService(Context.KEYGUARD_SERVICE) as KeyguardManager?
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O && keyguardManager != null) {
keyguardManager?.requestDismissKeyguard(this, object : KeyguardManager.KeyguardDismissCallback() {
override fun onDismissCancelled() {
super.onDismissCancelled()
Expand Down

0 comments on commit 1aff7e7

Please sign in to comment.