Make sure we have email on registerAccount page

Closes #179

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel 2019-10-04 18:33:38 +02:00
parent 471e8ac472
commit 7244eebc31
No known key found for this signature in database
GPG Key ID: A061B9DDE0CA0773
1 changed files with 7 additions and 0 deletions

View File

@ -88,6 +88,13 @@ export default class Register extends Vue {
validationSent: boolean = false;
sendingValidation: boolean = false;
async mounted() {
// Make sure no one goes to this page if we don't want to
if (!this.email) {
await this.$router.replace({ name: RouteName.PAGE_NOT_FOUND });
}
}
async submit() {
try {
this.sendingValidation = true;