Providing better feedback after wrong login
Change-Id: Icad837c2763d5c9623c26cc703f1a75f822d993c
diff --git a/src/app/core/login/login.ts b/src/app/core/login/login.ts
index 8aa40d5..d47f265 100644
--- a/src/app/core/login/login.ts
+++ b/src/app/core/login/login.ts
@@ -43,7 +43,12 @@
})
.catch(e => {
this.$log.error(`[XosLogin] Error during login.`, e);
- this.errorMsg = `Something went wrong, please try again.`;
+ if (e.error === 'XOSNotAuthenticated') {
+ this.errorMsg = `This combination of username/password cannot be authenticated`;
+ }
+ else {
+ this.errorMsg = `Something went wrong, please try again.`;
+ }
this.showErrorMsg = true;
});
}