diff --git a/app/views/registrations/_form.haml b/app/views/registrations/_form.haml index b9f99cfa5..5f3198881 100644 --- a/app/views/registrations/_form.haml +++ b/app/views/registrations/_form.haml @@ -32,7 +32,7 @@ placeholder: t("registrations.new.username"), title: t("registrations.new.enter_username"), required: true, - pattern: "[A-Za-z0-9_.\-]+", + pattern: "[A-Za-z0-9_.\\-]+", aria: {labelledby: "usernameLabel"} - if mobile diff --git a/app/views/sessions/_form.haml b/app/views/sessions/_form.haml index 4f480f1ad..fbefeaefc 100644 --- a/app/views/sessions/_form.haml +++ b/app/views/sessions/_form.haml @@ -19,7 +19,7 @@ placeholder: t("registrations.new.username"), class: "input-block-level form-control", required: true, - pattern: "[A-Za-z0-9_.@\-]+", + pattern: "[A-Za-z0-9_.@\\-]+", autocapitalize: "none", autocorrect: "off", autofocus: true,