What use case has the reload() function of a FirebaseUser in flutter?

Calling User.reload() reloads that user's profile data from the server.

A typical use-case for this is when you send an email to the user to verify their email address. When the user clicks the link in that email it goes back to the Firebase Authentication servers, which mark their email address as verified. But when this happens, there is no way for your app to know about it, since the call went straight from the email client to the server. So often you'll add a so-called continue URL to the link, which can call back into your app after the email address was verified. Then your app can call reload() to load the updated state from the server.


Lets you verify email without logging out, and logging in again. BUT it might be a bug, but when you call user.reload(), you have to call currentUser() again.

This does not work:

await user.reload();
user.isEmailVerified => still false

You need to:

await user.reload();
user = await _auth.currentUser();
user.isEmailVerified => now it is true