Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Firebase Token Error response handling #74

Closed
CR4567 opened this issue Dec 14, 2021 · 4 comments
Closed

Firebase Token Error response handling #74

CR4567 opened this issue Dec 14, 2021 · 4 comments

Comments

@CR4567
Copy link
Contributor

CR4567 commented Dec 14, 2021

I'm wondering about the error code handling of firebase.
See


There is a handling for error code "NotFound" and "InvalidArgument", but on firebase admin doc I can't find the notFound code. Instead for invalidating the token we should wait for "Unregistered". I would expect that this is the also the only response that should trigger an invalidation. All other errors are not related to the life of the token.
Bildschirmfoto 2021-12-14 um 14 21 48
https://firebase.google.com/docs/reference/admin/dotnet/namespace/firebase-admin/messaging#namespace_firebase_admin_1_1_messaging_1ac3482b9d4581255dee08b81ac3f677c9

@CR4567
Copy link
Contributor Author

CR4567 commented Dec 14, 2021

This are the parent errorCodes, but there are specific for messaging.
https://github.com/firebase/firebase-admin-dotnet/blob/master/FirebaseAdmin/FirebaseAdmin/Messaging/MessagingErrorCode.cs
Shouldn't you get these codes?

@SebastianStehle
Copy link
Collaborator

Sorry, there was another property. I have pushed a potential fix.

@CR4567
Copy link
Contributor Author

CR4567 commented Dec 14, 2021

ok looks good. That's what I would have expected.

@CR4567 CR4567 closed this as completed Dec 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants