From 971c402788ce0be1d005471513b3b9ebf9ff6613 Mon Sep 17 00:00:00 2001
From: Paul Frazee <pfrazee@gmail.com>
Date: Mon, 4 Dec 2023 12:45:40 -0800
Subject: Add PWI build flag (#2082)

---
 src/view/shell/createNativeStackNavigatorWithAuth.tsx | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

(limited to 'src/view/shell/createNativeStackNavigatorWithAuth.tsx')

diff --git a/src/view/shell/createNativeStackNavigatorWithAuth.tsx b/src/view/shell/createNativeStackNavigatorWithAuth.tsx
index c7b5d1d2e..43dc28159 100644
--- a/src/view/shell/createNativeStackNavigatorWithAuth.tsx
+++ b/src/view/shell/createNativeStackNavigatorWithAuth.tsx
@@ -1,5 +1,6 @@
 import * as React from 'react'
 import {View} from 'react-native'
+import {PWI_ENABLED} from '#/lib/build-flags'
 
 // Based on @react-navigation/native-stack/src/createNativeStackNavigator.ts
 // MIT License
@@ -99,7 +100,7 @@ function NativeStackNavigator({
   const {showLoggedOut} = useLoggedOutView()
   const {setShowLoggedOut} = useLoggedOutViewControls()
   const {isMobile} = useWebMediaQueries()
-  if (activeRouteRequiresAuth && !hasSession) {
+  if ((!PWI_ENABLED || activeRouteRequiresAuth) && !hasSession) {
     return <LoggedOut />
   }
   if (showLoggedOut) {
-- 
cgit 1.4.1

