# App Freez issue on launch ## Root Cause: - On app launch, once Auth0 token gets refreshed, app makes getCustomerAPI call to get customer info details. App waits fot customer info api's response (Success/failure), on response app start doing further setup of home page/tab setup etc. If getCustomer info API somehow cause delay in response then app start stucking/freezing on splash screen because all setup initialization depends on response. - I am able to reproduce app freez issue on app launch by adding response delay in getCustomerAPI. ## Solution - To avaoid freezing/stucking on splash screen, just remove app setup/initialization dependancy on getCustomerAPI response, app should not be stopping further setup/initialization of home page/tab bar configutations. To do that we just have to move app initialization function from getCustomerAPI response block into the initCoreData function that is getting called after remoteConfig fetch. With this solution, if getCustomerAPI times out still app will show cached data from core data and also if response comes little late then customer data automatically get refreshed in core data and app will show latest data when user go to account tab. This solution will work to solve app freez issue on app launch ## Deep Dive: Identity Service Consumption flow in iOS app - For Signed in user, On app launch, app makes Identity service call, after fetching firebase remote configurations to get user's details to store into Core data (Database) and app continues further to initialize app home screen setup (TabBar setup etc..).