Actually don't use requestSubmit() as it is not supported by Safari

https://caniuse.com/?search=requestSubmit
This commit is contained in:
Jean-Baptiste Bellet
2022-04-08 10:15:22 +02:00
parent a8afe7fee3
commit 5fe8060ea6

View File

@@ -56,7 +56,8 @@ export default class extends Controller {
this.brandTarget.setAttribute("value", response.paymentMethod.card.brand);
this.last4Target.setAttribute("value", response.paymentMethod.card.last4);
this.catchFormSubmit = false;
this.parentForm.requestSubmit();
event.submitter.click();
}
});
}