@@ -355,7 +355,6 @@ public void onCreate(@Nullable Bundle savedInstanceState) {
355
355
mIsMagicLinkSignup = getIntent ().getBooleanExtra (ARG_IS_MAGIC_LINK_SIGNUP , false );
356
356
mJetpackConnectSource = (JetpackConnectionSource ) getIntent ().getSerializableExtra (ARG_JETPACK_CONNECT_SOURCE );
357
357
String authTokenToSet = null ;
358
- boolean canShowAppRatingPrompt = savedInstanceState != null ;
359
358
360
359
mBottomNav = findViewById (R .id .bottom_navigation );
361
360
mBottomNav .init (getSupportFragmentManager (), this , mJetpackFeatureRemovalPhaseHelper );
@@ -419,8 +418,6 @@ public void onCreate(@Nullable Bundle savedInstanceState) {
419
418
&& getIntent ().getExtras ().getBoolean (ARG_CONTINUE_JETPACK_CONNECT , false )) {
420
419
JetpackConnectionWebViewActivity .startJetpackConnectionFlow (this , NOTIFICATIONS ,
421
420
(SiteModel ) getIntent ().getSerializableExtra (SITE ), mAccountStore .hasAccessToken ());
422
- } else {
423
- canShowAppRatingPrompt = true ;
424
421
}
425
422
}
426
423
} else {
@@ -469,30 +466,25 @@ && getIntent().getExtras().getBoolean(ARG_CONTINUE_JETPACK_CONNECT, false)) {
469
466
UpdateTokenPayload payload = new UpdateTokenPayload (authTokenToSet );
470
467
mDispatcher .dispatch (AccountActionBuilder .newUpdateAccessTokenAction (payload ));
471
468
} else if (getIntent ().getBooleanExtra (ARG_SHOW_LOGIN_EPILOGUE , false ) && savedInstanceState == null ) {
472
- canShowAppRatingPrompt = false ;
473
469
ActivityLauncher .showLoginEpilogue (
474
470
this ,
475
471
getIntent ().getBooleanExtra (ARG_DO_LOGIN_UPDATE , false ),
476
472
getIntent ().getIntegerArrayListExtra (ARG_OLD_SITES_IDS ),
477
473
mBuildConfigWrapper .isSiteCreationEnabled ()
478
474
);
479
475
} else if (getIntent ().getBooleanExtra (ARG_SHOW_SIGNUP_EPILOGUE , false ) && savedInstanceState == null ) {
480
- canShowAppRatingPrompt = false ;
481
476
ActivityLauncher .showSignupEpilogue (this ,
482
477
getIntent ().getStringExtra (SignupEpilogueActivity .EXTRA_SIGNUP_DISPLAY_NAME ),
483
478
getIntent ().getStringExtra (SignupEpilogueActivity .EXTRA_SIGNUP_EMAIL_ADDRESS ),
484
479
getIntent ().getStringExtra (SignupEpilogueActivity .EXTRA_SIGNUP_PHOTO_URL ),
485
480
getIntent ().getStringExtra (SignupEpilogueActivity .EXTRA_SIGNUP_USERNAME ), false );
486
481
} else if (getIntent ().getBooleanExtra (ARG_SHOW_SITE_CREATION , false ) && savedInstanceState == null ) {
487
- canShowAppRatingPrompt = false ;
488
482
ActivityLauncher .newBlogForResult (this ,
489
483
SiteCreationSource .fromString (getIntent ().getStringExtra (ARG_SITE_CREATION_SOURCE )));
490
484
} else if (getIntent ().getBooleanExtra (ARG_WP_COM_SIGN_UP , false ) && savedInstanceState == null ) {
491
- canShowAppRatingPrompt = false ;
492
485
ActivityLauncher .showSignInForResultWpComOnly (this );
493
486
} else if (getIntent ().getBooleanExtra (ARG_BLOGGING_PROMPTS_ONBOARDING , false )
494
487
&& savedInstanceState == null ) {
495
- canShowAppRatingPrompt = false ;
496
488
showBloggingPromptsOnboarding ();
497
489
}
498
490
@@ -501,10 +493,6 @@ && getIntent().getExtras().getBoolean(ARG_CONTINUE_JETPACK_CONNECT, false)) {
501
493
mGCMRegistrationScheduler .scheduleRegistration ();
502
494
}
503
495
504
- if (canShowAppRatingPrompt ) {
505
- AppReviewManager .INSTANCE .showRateDialogIfNeeded (getSupportFragmentManager ());
506
- }
507
-
508
496
scheduleLocalNotifications ();
509
497
initViewModel ();
510
498
@@ -1184,9 +1172,7 @@ protected void onResume() {
1184
1172
getSelectedPage ()
1185
1173
);
1186
1174
1187
- if (AppReviewManager .INSTANCE .shouldShowInAppReviewsPrompt ()) {
1188
- AppReviewManager .INSTANCE .launchInAppReviews (this );
1189
- }
1175
+ AppReviewManager .INSTANCE .showInAppReviewsPromptIfNecessary (this );
1190
1176
checkForInAppUpdate ();
1191
1177
1192
1178
mIsChangingConfiguration = false ;
0 commit comments