Skip to content

Commit

Permalink
GET requests do not need to send data. Breaks some webservers.
Browse files Browse the repository at this point in the history
  • Loading branch information
peterzal committed Jun 9, 2016
1 parent 5dc515c commit 71d56d3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sailthru/sailthru_http.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def sailthru_http_request(url, data, method, file_data=None):
"""
data = flatten_nested_hash(data)
method = method.upper()
params = data if method != 'POST' else None
params, data = (None, data) if method == 'POST' else (data, None)

try:
headers = {'User-Agent': 'Sailthru API Python Client %s; Python Version: %s' % ('2.3.0', platform.python_version())}
Expand Down

0 comments on commit 71d56d3

Please sign in to comment.