ruff: Fix SIM118 Use k not in d instead of k not in d.keys().

Signed-off-by: Anders Kaseorg <anders@zulip.com>
(cherry picked from commit 74d6d76046)
This commit is contained in:
Anders Kaseorg
2023-07-23 12:20:53 -07:00
committed by Alex Vandiver
parent 91e5ef39eb
commit 323223db4c
4 changed files with 7 additions and 7 deletions

View File

@@ -398,7 +398,7 @@ def validate_against_openapi_schema(
# No 500 responses have been documented, so skip them
if status_code.startswith("5"):
return False
if path not in openapi_spec.openapi()["paths"].keys():
if path not in openapi_spec.openapi()["paths"]:
endpoint = find_openapi_endpoint(path)
# If it doesn't match it hasn't been documented yet.
if endpoint is None: