_From @blaneyneil on July 12, 2018 22:29_
URL: https://pub.dartlang.org/packages/firebase_dynamic_links
i'm using version 0.0.5 and on iOS. i haven't ever been able to use:
dart
final PendingDynamicLinkData data = await FirebaseDynamicLinks.instance.retrieveDynamicLink();
and get a non-null value for that data var. that includes clicking on links i've generated in the firebase console, and thru buildUrl() and/or manually. it doesn't matter if the app is open in the bg, closed, or coming out of a hard reboot. and i've used both the simulator and a real device, and clicked on the link from sms and email.
generating links works as expected, and clicking on the link(s) always opens the app as expected (everything is configured properly in firebase and xcode). to make sure i wasn't missing anything i reduced my app to this entry point:
void main() async {
final PendingDynamicLinkData data = await FirebaseDynamicLinks.instance.retrieveDynamicLink();
print('main link = $data');
runApp(MaterialApp(
home: new LinksTest(data: data),
));
and rendered LinksTest like so:
import 'package:flutter/material.dart';
class LinksTest extends StatelessWidget {
var data;
LinksTest({this.data});
@override
Widget build(BuildContext context) {
return new Center(
child: new Text(data.toString(), style: new TextStyle(color: Colors.white, fontSize: 14.0)),
);
}
}
no matter what i do, the app always opens but data is always null.
_Copied from original issue: dart-lang/pub-dartlang-dart#1451_
@isoos
The issue at https://github.com/flutter/flutter/issues/19506 has been closed and moved here. Future collaboration on this issue will be done here.
facing the exact same issue. Tried with a vanilla firebase + flutter project. The iOS self-diagnostic tool says no errors found.
App launches, if installed, on clicking the link but the dynamic link is null. If the app in not installed, it redirects to app store correctly, but on launch the link is null.
Can someone please help on this? This has been bugging me for last 2 weeks!
@bparrishMines Would you mind taking a look at this?
this has long since been fixed after i opened the original ticket. @droid-it you should now be using getInitialLink and onLink.
@blaneyneil is correct. The current version of the plugin is 0.5.0+6. This should be fixed and the new implementation can be seen in step 4 of Handle Received Dynamic Links. https://pub.dev/packages/firebase_dynamic_links#-readme-tab- I'm closing this for now. Feel free to post if you're still experiencing this issue.
I am experiencing this issue. I am using getInitialLink and onLink. I am using firebase_dynamic_links version 0.5.0+9 and flutter 1.12.13+hotfix.7
Edit: Also does not work on 1.12.13+hotfix.8. It does work on my iOS simulator though.
Most helpful comment
facing the exact same issue. Tried with a vanilla firebase + flutter project. The iOS self-diagnostic tool says no errors found.
App launches, if installed, on clicking the link but the dynamic link is null. If the app in not installed, it redirects to app store correctly, but on launch the link is null.
Can someone please help on this? This has been bugging me for last 2 weeks!