Called when a new registration token is generated for the device. For example, this event can happen when a token expires or when the server invalidates the token.
This subscriber method is only called when the app is active (in the foreground).
Messaging instance.
Called with a FCM token when the token is refreshed.
Function to unsubscribe from the token refresh listener.
Called when a new registration token is generated for the device. For example, this event can happen when a token expires or when the server invalidates the token.