Skip to content

Commit 5cc73ea

Browse files
committed
update-suggested-changes
1 parent a34de52 commit 5cc73ea

File tree

2 files changed

+2
-16
lines changed

2 files changed

+2
-16
lines changed

openfga_sdk/client/client.py

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1184,14 +1184,7 @@ async def raw_request(
11841184

11851185
body_params = body
11861186
if "Content-Type" not in request_headers:
1187-
if isinstance(body, (dict, list)) or body is None:
1188-
request_headers["Content-Type"] = "application/json"
1189-
elif isinstance(body, str):
1190-
request_headers["Content-Type"] = "text/plain"
1191-
elif isinstance(body, bytes):
1192-
request_headers["Content-Type"] = "application/octet-stream"
1193-
else:
1194-
request_headers["Content-Type"] = "application/json"
1187+
request_headers["Content-Type"] = "application/json"
11951188

11961189
retry_params = None
11971190
if options and options.get("retry_params"):

openfga_sdk/sync/client/client.py

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1183,14 +1183,7 @@ def raw_request(
11831183

11841184
body_params = body
11851185
if "Content-Type" not in request_headers:
1186-
if isinstance(body, (dict, list)) or body is None:
1187-
request_headers["Content-Type"] = "application/json"
1188-
elif isinstance(body, str):
1189-
request_headers["Content-Type"] = "text/plain"
1190-
elif isinstance(body, bytes):
1191-
request_headers["Content-Type"] = "application/octet-stream"
1192-
else:
1193-
request_headers["Content-Type"] = "application/json"
1186+
request_headers["Content-Type"] = "application/json"
11941187

11951188
retry_params = None
11961189
if options and options.get("retry_params"):

0 commit comments

Comments
 (0)