diff --git a/plugins/Utilities.py b/plugins/Utilities.py index 5a5122d07..7f94bc2b1 100644 --- a/plugins/Utilities.py +++ b/plugins/Utilities.py @@ -122,6 +122,8 @@ class Utilities(callbacks.Privmsg): Returns the arguments given it. """ + if not args: + raise callbacks.ArgumentError irc.reply(msg, ' '.join(args), prefixName=False) def action(self, irc, msg, args): diff --git a/test/test_Utilities.py b/test/test_Utilities.py index 49a505ebe..066b9ac11 100644 --- a/test/test_Utilities.py +++ b/test/test_Utilities.py @@ -61,6 +61,7 @@ class UtilitiesTestCase(PluginTestCase, PluginDocumentation): self.assertResponse('strconcat foo bar baz', 'foobar baz') def testEcho(self): + self.assertHelp('echo') self.assertResponse('echo foo', 'foo') m = self.getMsg('cpustats') self.assertResponse('echo "%s"' % m.args[1], m.args[1])