diff options
author | Sean B. Palmer <http://inamidst.com/sbp/> | 2008-03-10 19:58:28 +0000 |
---|---|---|
committer | Sean B. Palmer <http://inamidst.com/sbp/> | 2008-03-10 19:58:28 +0000 |
commit | fb2cd452e963b8bc048161036903cd82d3b113f0 (patch) | |
tree | 81182d25fc19f538292b52a9e7c697447d5e6548 /modules/weather.py | |
parent | 5cad6661c9437832e23469aba2c9f04d94b734ee (diff) | |
download | bot-fb2cd452e963b8bc048161036903cd82d3b113f0.tar.gz bot-fb2cd452e963b8bc048161036903cd82d3b113f0.tar.bz2 bot-fb2cd452e963b8bc048161036903cd82d3b113f0.zip |
Some documentation and minor fixes.
Diffstat (limited to 'modules/weather.py')
-rwxr-xr-x | modules/weather.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/modules/weather.py b/modules/weather.py index 77f0fd0..787551c 100755 --- a/modules/weather.py +++ b/modules/weather.py @@ -84,6 +84,9 @@ def f_weather(self, origin, match, args): if args[0].startswith('.weather '): return icao_code = match.group(2) + if not icao_code: + return self.msg(origin.sender, 'Try .weather London, for example?') + if (not len(icao_code) == 4) or \ (len(icao_code) > 1 and icao_code[0] in 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' and icao_code[1] in 'abcdefghijklmnopqrstuvwxyz'): |