Skip to content

Commit

Permalink
don't try json decoding the empty string
Browse files Browse the repository at this point in the history
  • Loading branch information
JustinAzoff committed Jul 11, 2011
1 parent 2bb167e commit b252110
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from glob import glob


version = '0.1'
version = '0.2'

setup(name='splunky',
version=version,
Expand Down
2 changes: 2 additions & 0 deletions splunky/splunky.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ def post_xml(self, endpoint, data):
def get_json(self, endpoint, data):
d = data and urllib.urlencode(data) or ''
d = self.do('GET', endpoint + '?' + d)
if not d:
return None
return json.loads(d)

def get_xml(self, endpoint, data=None):
Expand Down

0 comments on commit b252110

Please sign in to comment.