This commit is contained in:
Jeremy Fincher 2003-12-02 11:06:39 +00:00
parent b473532b4c
commit 4e5e568244
2 changed files with 5 additions and 1 deletions

View File

@ -200,7 +200,10 @@ class Misc(callbacks.Privmsg):
name = privmsgs.getArgs(args, required=0, optional=1)
if name:
try:
module = sys.modules[name]
modules = {}
for moduleName in sys.modules:
modules[moduleName.lower()] = moduleName
module = sys.modules[modules[name.lower()]]
except KeyError:
irc.error(msg, 'I couldn\'t find a module named %s' % name)
return

View File

@ -156,6 +156,7 @@ class MiscTestCase(ChannelPluginTestCase, PluginDocumentation):
def testRevision(self):
self.assertNotError('revision Misc')
self.assertNotError('revision misc')
self.assertNotError('revision')