Fixed strjoin and added strconcat

This commit is contained in:
Jeremy Fincher 2003-03-15 00:55:43 +00:00
parent 4670e6df55
commit d2f56143dc

View File

@ -37,8 +37,12 @@ import callbacks
class Utils(callbacks.Privmsg): class Utils(callbacks.Privmsg):
def strjoin(self, irc, msg, args): def strjoin(self, irc, msg, args):
"<separator> <strings to join>" "<separator> <strings to join>"
(sep, text) = privmsgs.getArgs(args, needed=2) sep = args.pop(0)
irc.reply(msg, sep.join(text.split())) irc.reply(msg, sep.join(args))
def strconcat(self, irc, msg, args):
"<string 1> <string 2>"
(first, second) = privmsgs.getArgs(args, needed=2)
irc.reply(msg, first+second)
Class = Utils Class = Utils