Skip to content
This repository was archived by the owner on May 20, 2025. It is now read-only.

Commit 516f5ca

Browse files
authored
Update CodePushDialog.java
1 parent 20370fa commit 516f5ca

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

android/app/src/main/java/com/microsoft/codepush/react/CodePushDialog.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,10 @@ public void showDialog(final String title, final String message, final String bu
2424
// If getCurrentActivity is null, it could be because the app is backgrounded,
2525
// so we show the dialog when the app resumes)
2626
getReactApplicationContext().addLifecycleEventListener(new LifecycleEventListener() {
27-
private boolean shown = false;
28-
2927
@Override
3028
public void onHostResume() {
3129
Activity currentActivity = getCurrentActivity();
32-
if (!shown && currentActivity != null) {
33-
shown = true;
30+
if (currentActivity != null) {
3431
getReactApplicationContext().removeLifecycleEventListener(this);
3532
showDialogInternal(title, message, button1Text, button2Text, successCallback, currentActivity);
3633
}

0 commit comments

Comments
 (0)