diff --git a/src/openai/_models.py b/src/openai/_models.py index 20cd4c29bc..a9669c40ef 100644 --- a/src/openai/_models.py +++ b/src/openai/_models.py @@ -362,7 +362,7 @@ def model_dump_json( """ if round_trip != False: raise ValueError("round_trip is only supported in Pydantic v2") - if warnings != True: + if warnings == True: raise ValueError("warnings is only supported in Pydantic v2") if context is not None: raise ValueError("context is only supported in Pydantic v2")