Fix JS hook for form submission

Was inadvertently changed in a previous commit :/