From 13a633eea44743e7fb12cccdd646b54960a7494d Mon Sep 17 00:00:00 2001 From: Valentin Lorentz Date: Sat, 2 Feb 2013 19:47:14 +0100 Subject: [PATCH] Prevent traceback if supybot.replies.genericNoCapability is empty. --- src/callbacks.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/callbacks.py b/src/callbacks.py index e18838c8a..58c7025d9 100644 --- a/src/callbacks.py +++ b/src/callbacks.py @@ -519,7 +519,8 @@ class RichReplyMethods(object): v = self._getConfig(conf.supybot.replies.noCapability) v %= capability s = self.__makeReply(v, s) - return self._error(s, **kwargs) + if s: + return self._error(s, **kwargs) else: log.warning('Denying %s for some unspecified capability ' '(or a default).', self.msg.prefix)