Update backend/internal/service/gateway_request.go
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
@@ -507,11 +507,15 @@ func FilterSignatureSensitiveBlocksForRetry(body []byte) []byte {
|
|||||||
filtered = append(filtered, edit)
|
filtered = append(filtered, edit)
|
||||||
}
|
}
|
||||||
if len(filtered) != len(edits) {
|
if len(filtered) != len(edits) {
|
||||||
|
if len(filtered) == 0 {
|
||||||
|
delete(cm, "edits")
|
||||||
|
} else {
|
||||||
cm["edits"] = filtered
|
cm["edits"] = filtered
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
messages, ok := req["messages"].([]any)
|
messages, ok := req["messages"].([]any)
|
||||||
if !ok {
|
if !ok {
|
||||||
|
|||||||
Reference in New Issue
Block a user