diff --git a/src/components/views/auth/RegistrationForm.js b/src/components/views/auth/RegistrationForm.js
index 6e139d7051..c680d058c5 100644
--- a/src/components/views/auth/RegistrationForm.js
+++ b/src/components/views/auth/RegistrationForm.js
@@ -89,34 +89,37 @@ module.exports = React.createClass({
// is the one from the first invalid field.
// It's not super ideal that this just calls
// onValidationChange once for each invalid field.
- // TODO: Change this to trigger new-style validation for an invalid fields.
+ // TODO: Remove these calls once converted to new-style validation.
this.validateField(FIELD_PHONE_NUMBER, ev.type);
this.validateField(FIELD_EMAIL, ev.type);
this.validateField(FIELD_PASSWORD_CONFIRM, ev.type);
this.validateField(FIELD_PASSWORD, ev.type);
this.validateField(FIELD_USERNAME, ev.type);
+ const allFieldsValid = this.verifyFieldsBeforeSubmit();
+ if (!allFieldsValid) {
+ return;
+ }
+
const self = this;
- if (this.allFieldsValid()) {
- if (this.state.email == '') {
- const QuestionDialog = sdk.getComponent("dialogs.QuestionDialog");
- Modal.createTrackedDialog('If you don\'t specify an email address...', '', QuestionDialog, {
- title: _t("Warning!"),
- description:
-
- { _t("If you don't specify an email address, you won't be able to reset your password. " +
- "Are you sure?") }
-