fix linting

This commit is contained in:
Yuneng Jiang 2026-04-11 15:44:15 -07:00
parent 909247785e
commit c40e459447
No known key found for this signature in database

View file

@ -702,14 +702,14 @@ class BedrockGuardrail(CustomGuardrail, BaseAWSLLM):
"action": w.get("action"),
}
)
for w in word_policy.get("managedWordLists") or []:
if w.get("action") == "BLOCKED":
for mw in word_policy.get("managedWordLists") or []:
if mw.get("action") == "BLOCKED":
word_matches.append(
{
"category": "managedWordLists",
"type": w.get("type"),
"match": w.get("match"),
"action": w.get("action"),
"type": mw.get("type"),
"match": mw.get("match"),
"action": mw.get("action"),
}
)
if word_matches: