Skip to content

Commit 13bfb1f

Browse files
Potential fix for pull request finding
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
1 parent 189d17b commit 13bfb1f

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

broker/patron_request/api/api-handler.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -528,7 +528,9 @@ func (a *PatronRequestApiHandler) PutPatronRequestsId(w http.ResponseWriter, r *
528528
logParams["symbol"] = symbol
529529
ctx = common.CreateExtCtxWithArgs(r.Context(), &common.LoggerArgs{Other: logParams})
530530

531-
if newPr.Id == nil || *newPr.Id != id {
531+
if newPr.Id == nil {
532+
newPr.Id = &id
533+
} else if *newPr.Id != id {
532534
api.AddBadRequestError(ctx, w, fmt.Errorf("patron request id does not match"))
533535
return
534536
}

0 commit comments

Comments
 (0)