Skip to content

Commit f0564e1

Browse files
author
yuguo.dtpe
committed
feature: empty body sign handler
1 parent 43ed87d commit f0564e1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

volcenginesdkcore/interceptor/interceptors/sign_request_interceptor.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ def update_params_for_auth(host, path, method, headers, querys, auth_settings, b
3939

4040
for auth in auth_settings:
4141
headers["Host"] = host
42-
if method in ["POST", "PUT", "DELETE", "PATCH"]:
42+
if method in ["POST", "PUT", "DELETE", "PATCH"] and body is not None:
4343
body = json.dumps(body)
4444
else:
4545
body = ""

0 commit comments

Comments
 (0)