Skip to content

Commit

Permalink
Added a debug log message when request is denied
Browse files Browse the repository at this point in the history
  • Loading branch information
dehort committed Sep 24, 2024
1 parent 35fa754 commit d14f5df
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions internal/api/controllers/private/runsCreate.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ func (this *controllers) ApiInternalRunsCreate(ctx echo.Context) error {
}

if utils.IsOrgIdBlocklisted(this.config, orgIdString) {
utils.GetLogFromEcho(ctx).Debugw("Rejecting request because the org_id is blocklisted")
return handleRunCreateError(&utils.BlocklistedOrgIdError{OrgID: orgIdString})
}

Expand Down
1 change: 1 addition & 0 deletions internal/api/controllers/private/runsCreateV2.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ func (this *controllers) ApiInternalV2RunsCreate(ctx echo.Context) error {
context = utils.WithRequestType(context, getRequestTypeLabel(runInputV2))

if utils.IsOrgIdBlocklisted(this.config, string(runInputV2.OrgId)) {
utils.GetLogFromEcho(ctx).Debugw("Rejecting request because the org_id is blocklisted")
return handleRunCreateError(&utils.BlocklistedOrgIdError{OrgID: string(runInputV2.OrgId)})
}

Expand Down

0 comments on commit d14f5df

Please sign in to comment.