Hello,
for some reason some users who register on my app dont have token saved and i dont get an error.
Your code seems no problem, Please check the method GenericMethods.StorePushToken
, it would be the reason the error occurs.
manually register the device and get a token
It's no way to set the device token for Firebase Cloud Messaging by yourself. It would actually be an antipattern to set a user's ID, due to the same user may end up using the app on different devices.
Best Regards,
Alec Liu.
If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.