Skip to content

Commit

Permalink
chore: incorrect order of spinner activation
Browse files Browse the repository at this point in the history
  • Loading branch information
Soare-Robert-Daniel committed Aug 21, 2023
1 parent 2d72965 commit 5d2a477
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/blocks/frontend/form/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -377,7 +377,7 @@ const collectAndSendInputFormData = async( form, btn, displayMsg ) => {
const hasValidToken = id && window.themeisleGutenberg?.tokens?.[id]?.token;

const spinner = makeSpinner( btn );
spinner.show();


if ( formIsEmpty ) {
btn.disabled = false;
Expand Down Expand Up @@ -461,6 +461,7 @@ const collectAndSendInputFormData = async( form, btn, displayMsg ) => {
body: formData
});

spinner.show();
handleAfterSubmit(
request,
displayMsg,
Expand Down

0 comments on commit 5d2a477

Please sign in to comment.