diff --git a/abbott/plugins/admin.py b/abbott/plugins/admin.py index 50e36ba..66b0dd1 100644 --- a/abbott/plugins/admin.py +++ b/abbott/plugins/admin.py @@ -128,7 +128,7 @@ def _has_op(self, channel): defer.returnValue( self.have_op[channel] ) except KeyError: # determine if we have OP - names_list = (yield self.transport.issue_request("irc.names",channel)) + names_list = (yield self.transport.issue_request("irc.names",channel)).split() nick = (yield self.transport.issue_request("irc.getnick")) @@ -554,7 +554,7 @@ def start(self): cmdname="quiet", cmdmatch="quiet|QUIET", cmdusage=" [for ]", - argmatch = "(?P[^ ]+)(?: (?:for )?{0})?$".format(duration_match), + argmatch = "(?P[^ ]+)(?: (?:for )?{0}+)?$".format(duration_match), prefix=".", permission="irc.op.quiet", callback=self.quiet, @@ -565,7 +565,7 @@ def start(self): cmdname="unquiet", cmdmatch="unquiet|UNQUIET", cmdusage=" [in ]", - argmatch = "(?P[^ ]+)(?: (?:in )?{0})?$".format(duration_match), + argmatch = "(?P[^ ]+)(?: (?:in )?{0}+)?$".format(duration_match), prefix=".", permission="irc.op.quiet", callback=self.unquiet, @@ -577,7 +577,7 @@ def start(self): cmdname="ban", cmdmatch="ban|BAN", cmdusage=" [for ] [reason]", - argmatch = "(?P[^ ]+)(?: (?:for )?{0})?(?: (?P.+))?$".format(duration_match), + argmatch = "(?P[^ ]+)(?: (?:for )?{0}+)?(?: (?P.+))?$".format(duration_match), prefix=".", permission="irc.op.ban", callback=self.ban, @@ -588,7 +588,7 @@ def start(self): cmdname="unban", cmdmatch="unban|UNBAN", cmdusage=" [in ]", - argmatch = "(?P[^ ]+)(?: (?:in )?{0})?$".format(duration_match), + argmatch = "(?P[^ ]+)(?: (?:in )?{0}+)?$".format(duration_match), prefix=".", permission="irc.op.ban", callback=self.unban,