Skip to content

Commit

Permalink
fix(createAccount): prevent reload on invalid submission
Browse files Browse the repository at this point in the history
  • Loading branch information
josephmcg committed Jun 9, 2022
1 parent ae46dd3 commit 0b4541d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion components/views/user/create/Create.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
/>
<div v-if="showCropper" class="cropper-mask" />
<div class="modal-body">
<form @submit="confirm">
<form @submit="confirm" novalidate>
<div class="custom-modal-content">
<div class="columns">
<div class="column image">
Expand Down
3 changes: 1 addition & 2 deletions components/views/user/create/Create.vue
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,7 @@ export default Vue.extend({
* @example this.onConfirm()
*/
confirm(e: Event) {
e.preventDefault()
if (this.isLoading) {
return
}
Expand All @@ -179,8 +180,6 @@ export default Vue.extend({
}) as string
return
}
e.preventDefault()
this.error = ''
this.$emit('confirm', {
Expand Down

0 comments on commit 0b4541d

Please sign in to comment.