title: react firebase auth displayName return null
body: <p>Im trying to do firebase auth in conformity with google documentation. After user is registered he is redirecting to '/' path, then im getting user display name by onAuthStateChangedListener but it return null, although im checking full user data file and contains displayName field.</p>
  <p>auth code</p>
  <pre><code>firebase
            .auth()
            .createUserWithEmailAndPassword(email, password)
            .then((result) =&gt; {
              result.user
                .updateProfile({
                  displayName: nickname,
                })
  </code></pre>
  <p>getting user data code</p>
  <pre><code>firebase.auth().onAuthStateChanged((data) =&gt; {
        if (data) setUser(data);
        console.log(data);
      });
  </code></pre>
  <p>screen with contains display name<a href="https://i.stack.imgur.com/TLbRv.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/TLbRv.png" alt="enter image description here" /></a></p>