From f130db33cca17970c979a4e80c0b1a88cb11ddd5 Mon Sep 17 00:00:00 2001 From: James Vega Date: Fri, 26 Mar 2004 00:56:31 +0000 Subject: [PATCH] Better error checking with Http.stockquote and remove Http.weather's tests. --- plugins/Http.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/plugins/Http.py b/plugins/Http.py index c0faaad37..ca3f9f688 100644 --- a/plugins/Http.py +++ b/plugins/Http.py @@ -172,6 +172,9 @@ class Http(callbacks.Privmsg): previous day of a given compny (represented by a stock symbol). """ symbol = privmsgs.getArgs(args) + if ' ' in symbol: + irc.error('Only one stockquote can be looked up at a time.') + return url = 'http://finance.yahoo.com/d/quotes.csv?s=%s' \ '&f=sl1d1t1c1ohgv&e=.csv' % symbol quote = webutils.getUrl(url)