@@ -318,21 +318,14 @@ const maybeDoneWithLogoutHandshake = async (state: Container.TypedState) => {
318318 }
319319}
320320
321- const showMonsterPushPrompt = ( ) => [
322- RouteTreeGen . createSwitchLoggedIn ( { loggedIn : true } ) ,
323- RouteTreeGen . createSwitchTab ( { tab : Tabs . peopleTab } ) ,
324- RouteTreeGen . createNavigateAppend ( {
325- path : [ 'settingsPushPrompt' ] ,
326- } ) ,
327- ]
328-
329321// Monster push prompt
330322// We've just started up, we don't have the permissions, we're logged in and we
331323// haven't just signed up. This handles the scenario where the push notifications
332324// permissions checker finishes after the routeToInitialScreen is done.
333- const onShowPermissionsPrompt = (
325+ const onShowPermissionsPrompt = async (
334326 state : Container . TypedState ,
335- action : PushGen . ShowPermissionsPromptPayload
327+ action : PushGen . ShowPermissionsPromptPayload ,
328+ listenerApi : Container . ListenerApi
336329) => {
337330 if (
338331 ! Platform . isMobile ||
@@ -345,7 +338,10 @@ const onShowPermissionsPrompt = (
345338 }
346339
347340 logger . info ( '[ShowMonsterPushPrompt] Entered through the late permissions checker scenario' )
348- return showMonsterPushPrompt ( )
341+ listenerApi . dispatch ( RouteTreeGen . createSwitchLoggedIn ( { loggedIn : true } ) )
342+ await Container . timeoutPromise ( 100 )
343+ listenerApi . dispatch ( RouteTreeGen . createSwitchTab ( { tab : Tabs . peopleTab } ) )
344+ listenerApi . dispatch ( RouteTreeGen . createNavigateAppend ( { path : [ 'settingsPushPrompt' ] } ) )
349345}
350346
351347const onAndroidShare = ( state : Container . TypedState ) => {
0 commit comments