aboutsummaryrefslogtreecommitdiffhomepage
path: root/backend/auth/auth.go
diff options
context:
space:
mode:
Diffstat (limited to 'backend/auth/auth.go')
-rw-r--r--backend/auth/auth.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/backend/auth/auth.go b/backend/auth/auth.go
index b79161f..7d9a4c2 100644
--- a/backend/auth/auth.go
+++ b/backend/auth/auth.go
@@ -39,7 +39,7 @@ func Login(
// Authenticate with password.
passwordHash := userAuth.PasswordHash
if passwordHash == nil {
- panic("inconsistant data")
+ return 0, errors.New("inconsistent data: password auth type but no password hash")
}
err := bcrypt.CompareHashAndPassword([]byte(*passwordHash), []byte(password))
if err != nil {