android-branch-deep-linking-attribution icon indicating copy to clipboard operation
android-branch-deep-linking-attribution copied to clipboard

Branch IO deep link always opens splash activity

Open Abhishek284 opened this issue 3 years ago • 5 comments

I have integrated BranchIO in splash activity(i.e. The Launcher Activity).

case 1: When the app is not in the background and I click on the deep link, SplashActivity is opened. (Works fine)

case 2: When I am already logged in and put the app in the background, on click on the deep link the app again restarts with Splash Activity

I want the app to be resumed in whichever state it was left when I click on the deep link. How to achieve this?

One solution would be to handle navigation in SplashActivity whenever the app is opened via a link, but that is not feasible here. We just want to launch the app in whichever state it was left before

Abhishek284 avatar Mar 10 '21 11:03 Abhishek284

Hello @Abhishek284,

Have you set the launch mode to SingleTask for your splash activity?

lounerios avatar Aug 16 '21 11:08 lounerios

Hey @Abhishek284,

Could you provide us with steps to reproduce while also confirming our integration instructions?

jf-branch avatar Oct 17 '21 07:10 jf-branch

From my observation, the branch links opens only launcher activity.(No matter whether the app is in background or not). If user have navigated to some different activity within app and puts the app is background, and then clicks on a deeplink from email or messages, the app restarts with launcher activity. I think this is a limitation.

Abhishek284 avatar Oct 19 '21 07:10 Abhishek284

I have faced the same issue when I put the logic into Splash/Launcher activity. It was always opening the app from Launcher Activity. From fresh launch or bringing the app from background to foreground when I click the deeplink.

ercanpinar avatar Nov 15 '21 01:11 ercanpinar

I had to move my logic to MainActivity to solve this issue.

ercanpinar avatar Dec 20 '21 23:12 ercanpinar