Skip to content

Beautiful Open-Source Form Builder

fix password reset bug (#559)

Favour Olayinkad4990ec4db79
diff --git a/client/components/pages/auth/ForgotPasswordModal.vue b/client/components/pages/auth/ForgotPasswordModal.vue
index a92c9995a..6794f1920 100644
--- a/client/components/pages/auth/ForgotPasswordModal.vue
+++ b/client/components/pages/auth/ForgotPasswordModal.vue
@@ -150,8 +150,15 @@ export default {
}),
methods: {
async send() {
- await this.form.post("/password/email")
- this.isMailSent = true
+ await this.form.post("/password/email").then(() => {
+ this.isMailSent = true
+ }).catch(error => {
+ if(error?.data?.email){
+ useAlert().error(error.data?.email)
+ this.isMailSent = false
+ }
+ }
+ )
},
close() {
this.$emit("close")