Javascript 我希望在重新发送otp时避免重新进行TCHA验证

Javascript 我希望在重新发送otp时避免重新进行TCHA验证,javascript,Javascript,预期成果: 在请求重新发送otp时,用户无需执行recaptcha验证。 实际结果: 但是,我在重新发送otp时再次获得了recaptcha验证 enter code here 下面是我写的代码,有什么建议吗 if (window.recaptchaVerifier) window.recaptchaVerifier.render().then((widgetId) => { grecaptcha.reset(widgetId); cons

预期成果: 在请求重新发送otp时,用户无需执行recaptcha验证。 实际结果: 但是,我在重新发送otp时再次获得了recaptcha验证

enter code here
下面是我写的代码,有什么建议吗



if (window.recaptchaVerifier)
       window.recaptchaVerifier.render().then((widgetId) => {
        grecaptcha.reset(widgetId);
       console.log('Recaptcha not required!! Hence signing in')

       this.signInWithPhoneNumber();
     });
     else {
       if(this.showRecaptcha){
       window.recaptchaVerifier = new firebase.auth.RecaptchaVerifier('firebase-phone-signin', {
         'size': 'invisible',
         'callback': (response) => {
           // reCAPTCHA solved, allow signInWithPhoneNumber.
           console.log('Recaptcha solved!! Hence signing in')

         }
     });