1

I am using firebase_messaging to manage notifications on a Flutter app.
No problems with Android.
When I try in iOS to subscibe to a topic (again, which WORKS PERFECTLY on Android) I get no error, but I've understood that something bad is happening in the background, since the next line of code is always skipped, exactly like when Flutter goes in exception:

void _subscribeToTopic(String topic) async {
    await FCMHelper.firebaseMessaging.subscribeToTopic(topic);
    await SharedPrefsHelper.sp.setBool(topic, true);
}

The await SharedPrefsHelper.sp.setBool(topic, true); is NEVER executed, meaning that subscribeToTopic is going in error.
I'm astonished that as it seems, nobody had this problem before me (no issue on GitHub, no question on StackOverflow) but I really don't know what to do, especially because I don't know Swift nor Objective-C, so if there is a bug in the code, I'm not able to find it.
Please help me. Thanks

Ale TheFe
  • 1,540
  • 15
  • 43

1 Answers1

0

solved by deleting and re installing pod files

As what in the following GitHub issue https://github.com/FirebaseExtended/flutterfire/issues/1943

To delete and re installing pod files see this link Flutter iOS build failed an error of pod files: Podfile is out of date

khawla
  • 1
  • 1