[jsonbot] replacing spaces with %20 in queried url

This commit is contained in:
Max 2015-07-06 23:21:14 +01:00 committed by nemunaire
parent 6e226f0fb3
commit b5e4acdb70

View File

@ -46,7 +46,7 @@ def get_json_info(msg):
if len(msg.cmds) < 2:
raise IRCException("Please specify a url and a list of JSON keys.")
request_data = web.getURLContent(msg.cmds[1])
request_data = web.getURLContent(msg.cmds[1].replace(' ', "%20"))
if not request_data:
raise IRCException("Please specify a valid url.")
json_data = json.loads(request_data)