iOS app always handle the previous deeplink
1. Click deeplink from Notes app; goes to AppStore and DO NOT install it
2. Instead install the app to the device manually from Xcode
-right now im have not deployed this to production yet and still in development stage…and this is how I simulate the download from appstore and do the then deeplink scenario…correct me if theres a correct way to do it
3. Open the app and goes to the desired page
4. Close the app (should not be running from the background)
5. Then click the app icon
6. It will then perform #3
7. Then if I wait let say 10 mins, the issue goes away
Is this normal?
Will this not happen in production when downloading the app from appstore?
This seems to be a problem with Branch implementation. Can you share your App Delegate file ? Here are few pointers for your App Delegate file that will come in handy in this case.
- Move your Branch calls to the top of didFinishLaunchingWithOptions
- While troubleshooting, call setDebug immediately after Branch *branch = [Branch getInstance];
- Structure your routing functions as shown in the documentation here: https://github.com/BranchMetrics/ios-branch-deep-linking#methods-1
- Make sure that your openURL method (“- (BOOL)application:(UIApplication *)application openURL”) includes a call to [[Branch getInstance] handleDeepLink:url];
- As you are using the Facebook SDK, be sure to call the
accountForFacebookSDKPreventingAppLaunch method (see:https://dev.branch.io/getting-started/universal-app-links/support/ios/#using-facebooks-sdk)
Also, in case you have not already checked them out, there are two sample apps available to serve as reference models:
- The TestBed app that is included with the SDK (use the Objective-C version in the Staging branch:https://github.com/BranchMetrics/ios-branch-deep-linking/tree/staging/Branch-TestBed)
- The Branch Monster Factory app (here: https://github.com/BranchMetrics/Branch-Example-Deep-Linking-Branchster-iOS/tree/Staging). The Staging branch includes a Readme with instructions on setting up your own copy of the app – it takes about 5 minutes to set up.