Skip to content

Commit

Permalink
Merge pull request #124 from magento-l3/L3-PR-2023-09-13
Browse files Browse the repository at this point in the history
L3 pr 2023 09 13
  • Loading branch information
dhorytskyi authored Oct 3, 2023
2 parents 68488df + 9ae8dd0 commit 46a5e0b
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions ReCaptchaFrontendUi/view/frontend/web/js/reCaptcha.js
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,13 @@ define(
grecaptcha.execute(widgetId);
event.preventDefault(event);
event.stopImmediatePropagation();
if (this.$parentForm.valid()) {
let formSubmitButton = this.$parentForm.find('button:not([type]), [type=submit]');

if (formSubmitButton.length) { //eslint-disable-line max-depth
formSubmitButton.attr('disabled', true);
}
}
}
}.bind(this));

Expand Down

0 comments on commit 46a5e0b

Please sign in to comment.