From 4b1e5b5a74cdf99628fe439b03b99bfa44bc2f75 Mon Sep 17 00:00:00 2001 From: Jeremy Fincher Date: Fri, 27 Feb 2004 17:20:57 +0000 Subject: [PATCH] Don't display errors in snarfers,, mo. --- plugins/URL.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/plugins/URL.py b/plugins/URL.py index fb4c0081b..a86aeae78 100644 --- a/plugins/URL.py +++ b/plugins/URL.py @@ -197,7 +197,11 @@ class URL(callbacks.PrivmsgCommandAndRegexp, channel = msg.args[0] if self.registryValue('titleSnarfer', channel): url = match.group(0) - text = webutils.getUrl(url, size=conf.supybot.httpPeekSize()) + try: + text = webutils.getUrl(url, size=conf.supybot.httpPeekSize()) + except webutils.WebError, e: + self.log.info('Couldn\'t snarf title of %s, %s.', url, e) + return m = self._titleRe.search(text) if m is not None: domain = webutils.getDomain(url)