Skip to content
This repository has been archived by the owner on May 7, 2024. It is now read-only.

Commit

Permalink
fix delete method
Browse files Browse the repository at this point in the history
  • Loading branch information
fawaf committed Oct 15, 2015
1 parent 3c48798 commit 6fff910
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion cloudflare_v4/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,10 @@ def call(self, method, main_endpoint, endpoint=None, params=None, data=None):
elif method == 'POST':
response = requests.post(url, headers=headers, json=data)
elif method == 'DELETE':
response = requests.delete("%s/%s" % (url, data), headers=headers)
if data:
response = requests.delete(url, headers=headers, json=data)
else:
response = requests.delete(url, headers=headers)
elif method == 'PATCH':
pass
else:
Expand Down

0 comments on commit 6fff910

Please sign in to comment.