avioli / uni_links

Flutter plugin for accepting incoming links.
BSD 2-Clause "Simplified" License
563 stars 303 forks source link

Not able to move to next screen when app is running in back ground #125

Open Nilesh-Chaudahri opened 3 years ago

Nilesh-Chaudahri commented 3 years ago

Suppose app is running in back ground. I click on link present on my email. I get suggestion to open it from My_Flutter_App, click on My_Flutter_App and redirected to My_Flutter_App. i have already implemented social sign up login using simple_auth which is working fine. now click on any social media icon,through authentication i got the require information but i am not able to move to next screen.control is passing the Navigator.push(...); but still not able to push to next line

above scenario is working fine if my app is not running in back ground. @avioli

echomartha commented 3 years ago

added this code

_sub = uriLinkStream.listen((Uri? uri) {
      // your code to move next screen
    }, onError: (err) {
      // Handle exception by warning the user their action did not succeed
    });
kimmy-wang commented 3 years ago

@echomartha Using a custom URL scheme, after waking up the app from the background, the link information cannot be obtained, and the link information can be obtained using universal link.