diff options
author | Santo Cariotti <santo@dcariotti.me> | 2022-09-28 15:53:24 +0200 |
---|---|---|
committer | Santo Cariotti <santo@dcariotti.me> | 2022-09-28 15:53:24 +0200 |
commit | 2e612d1aa02acfdd8fa47408819ee42df57cbe48 (patch) | |
tree | 3b64952674b0db33a5d98c2a8615636448146a1f /pages/signin.vue | |
parent | c27871343a26da4e20e4e601dacebe8ef9b419ef (diff) |
Fix error
Diffstat (limited to 'pages/signin.vue')
-rw-r--r-- | pages/signin.vue | 6 |
1 files changed, 5 insertions, 1 deletions
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); |