Skip to content

SigNoz is an open-source, OpenTelemetry-native observability platform for your team and their AI agents. Get logs, metrics, and traces in one tool with features like APM, distributed tracing, log management, infra monitoring, etc. Combined with SigNoz MCP and a native AI teammate (in SigNoz Cloud) it helps you build more resilient apps.

fix: add error message in login (#8010)

Nityananda Gohaina1c7a948fac5
diff --git a/pkg/modules/user/impluser/module.go b/pkg/modules/user/impluser/module.go
index 3635c01e03..03d29490af 100644
--- a/pkg/modules/user/impluser/module.go
+++ b/pkg/modules/user/impluser/module.go
@@ -310,7 +310,9 @@ func (m *Module) GetAuthenticatedUser(ctx context.Context, orgID, email, passwor
if err != nil {
return nil, err
}
- if len(user) == 1 {
+ if len(user) == 0 {
+ return nil, errors.Newf(errors.TypeInvalidInput, errors.CodeInvalidInput, "user with email: %s does not exist", email)
+ } else if len(user) == 1 {
dbUser = &user[0].User
} else {
return nil, errors.New(errors.TypeInvalidInput, errors.CodeInvalidInput, "please provide an orgID")