mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-11-27 10:42:45 +03:00
🐛 Fixed members form missing data-members-name (#12250)
refs #12249 This was incorrectly assuming the presence of the data-members-name element in the document. By guarding against it and defaulting to undefined, we fallback to the existing behaviour when the element is not present.
This commit is contained in:
parent
244704156c
commit
ce14d8113a
@ -11,7 +11,7 @@ Array.prototype.forEach.call(document.querySelectorAll('form[data-members-form]'
|
||||
var emailInput = event.target.querySelector('input[data-members-email]');
|
||||
var nameInput = event.target.querySelector('input[data-members-name]');
|
||||
var email = emailInput.value;
|
||||
var name = nameInput.value;
|
||||
var name = nameInput && nameInput.value || undefined;
|
||||
var emailType = undefined;
|
||||
var labels = [];
|
||||
|
||||
|
2
core/server/public/members.min.js
vendored
2
core/server/public/members.min.js
vendored
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue
Block a user