Skip to content

Commit 01b5000

Browse files
Fixed WordPress 4.7 compatibility, closes #23
1 parent b248bb8 commit 01b5000

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

woocommerce/api.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@ def __request(self, method, endpoint, data):
6464
params = {}
6565
headers = {
6666
"user-agent": "WooCommerce API Client-Python/%s" % __version__,
67-
"content-type": "application/json;charset=utf-8",
6867
"accept": "application/json"
6968
}
7069

@@ -80,6 +79,7 @@ def __request(self, method, endpoint, data):
8079

8180
if data is not None:
8281
data = jsonencode(data, ensure_ascii=False).encode('utf-8')
82+
headers["content-type"] = "application/json;charset=utf-8"
8383

8484
return request(
8585
method=method,

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy