Skip to content

Commit

Permalink
Remove superfluous case-treatment;
Browse files Browse the repository at this point in the history
  • Loading branch information
joergdw committed Aug 16, 2024
1 parent a85e97e commit cd1c00c
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions src/autoscaler/db/sqldb/storedprocedure_sqldb.go
Original file line number Diff line number Diff line change
Expand Up @@ -121,13 +121,7 @@ func (sdb *StoredProcedureSQLDb) ValidateCredentials(ctx context.Context, creds
err := sdb.sqldb.QueryRow(ctx, query, creds.Username, creds.Password, appId).
Scan(&credOptions.InstanceId, &credOptions.BindingId)

if err == pgx.ErrNoRows {
sdb.logger.Info(
"user found but does not own the app behind the binding",
err, lager.Data{"query": query, "creds": creds, "appId": appId})

return nil, errors.New("user found but does not own the app")
} else if err != nil {
if err != nil {
sdb.logger.Error(
"credential-validation-with-stored-function-errored",
err, lager.Data{"query": query, "creds": creds, "appId": appId})
Expand Down

0 comments on commit cd1c00c

Please sign in to comment.