From 2e612d1aa02acfdd8fa47408819ee42df57cbe48 Mon Sep 17 00:00:00 2001 From: Santo Cariotti Date: Wed, 28 Sep 2022 15:53:24 +0200 Subject: Fix error --- pages/signin.vue | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'pages') diff --git a/pages/signin.vue b/pages/signin.vue index de80c05..c0a4342 100644 --- a/pages/signin.vue +++ b/pages/signin.vue @@ -50,7 +50,11 @@ export default { event.preventDefault(); const f = this.form; - if (!(f.username && f.password)) return; + if (!(f.username && f.password)) { + this.$toast.error("Every field is required"); + return; + } + this.$store.dispatch("auth/login", f).then((response) => { if (response.status != 200) { this.$toast.error(response.data.error); -- cgit v1.2.3-18-g5258