title: Firebase Authentication: Calling `createUserWithEmailAndPassword` calls `createAuthUri` on error
body: <p>Calling <code>firebase.auth().createUserWithEmailAndPassword(email, password)</code> is causing <code>&quot;QUOTA_EXCEEDED : Exceeded quota for email lookup.&quot;</code> if a user tries to create an account with an existing email.</p>
  <p>Here is my code (using <code>&quot;firebase&quot;: &quot;7.6.2&quot;</code>):</p>
  <pre><code> firebase.auth().createUserWithEmailAndPassword(email, password)
        .then(result =&gt; {
           result.user.sendEmailVerification(actionCodeSettings);
        })
        .catch(error =&gt; {
          console.log(error);
          // Handling error for user
        });
  </code></pre>
  <p>The error is handled correctly. The error is catched with</p>
  <pre><code>  &quot;error&quot;: {
      &quot;code&quot;: 400,
      &quot;message&quot;: &quot;EMAIL_EXISTS&quot;,
      &quot;errors&quot;: [
        {
          &quot;message&quot;: &quot;EMAIL_EXISTS&quot;,
          &quot;domain&quot;: &quot;global&quot;,
          &quot;reason&quot;: &quot;invalid&quot;
        }
      ]
    }
  }
  </code></pre>
  <p>Nevertheless firebase is calling <code>createAuthUri</code> to create the URI used by the IdP to authenticate the user. This call is triggered in a loop till it runs into the quota.
  Has anybody the same problem? How can i cancel the calls of <code>createAuthUri</code> to avoid to run against the quota?</p>
  <p><a href="https://i.stack.imgur.com/KOcma.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/KOcma.png" alt="enter image description here" /></a>
  <a href="https://i.stack.imgur.com/8lTmb.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/8lTmb.png" alt="enter image description here" /></a></p>