From 9add4128711a97a1a1b5006a6302f0d016669fa5 Mon Sep 17 00:00:00 2001 From: Ben Kurtovic Date: Sun, 14 Apr 2013 01:36:04 -0400 Subject: [PATCH] A couple of fixes. --- commands/weather.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/commands/weather.py b/commands/weather.py index 7bb95a8..a12ed9d 100644 --- a/commands/weather.py +++ b/commands/weather.py @@ -60,7 +60,7 @@ class Weather(Command): msg = " ".join(("Where do you want the weather of? You can", "set a default with '!{0} default City,", "State' (or 'City, Country' if non-US).")) - self.reply(data, msg) + self.reply(data, msg.format(data.command)) return elif data.args[0] == "default": if data.args[1:]: @@ -80,7 +80,7 @@ class Weather(Command): location = " ".join(data.args) url = "http://api.wunderground.com/api/{0}/conditions/q/{1}.json" - location = quote("_".join(location), safe="") + location = quote(location, safe="") query = urlopen(url.format(self.key, location)).read() res = loads(query)