Skip to content

Commit

Permalink
fix another TypeError in jsSubmit
Browse files Browse the repository at this point in the history
  • Loading branch information
Changaco committed Nov 2, 2024
1 parent b7cb6f2 commit d9eab44
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion js/forms.js
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ Liberapay.forms.jsSubmit = function() {
// Determine the submission mode
var form_on_success = form.getAttribute('data-on-success');
var button, button_on_success;
if (e.submitter.tagName == 'BUTTON') {
if (e.submitter && e.submitter.tagName == 'BUTTON') {
button = e.submitter;
button_on_success = button.getAttribute('data-on-success');
}
Expand Down

0 comments on commit d9eab44

Please sign in to comment.