mirror of https://github.com/Mikaela/Limnoria.git
This should allow contexts where we allow converters.
This commit is contained in:
parent
ac57418802
commit
60966044b1
|
@ -601,10 +601,12 @@ class context(object):
|
||||||
self.converter = getConverter(spec[0])
|
self.converter = getConverter(spec[0])
|
||||||
elif spec is None:
|
elif spec is None:
|
||||||
self.converter = getConverter('anything')
|
self.converter = getConverter('anything')
|
||||||
else:
|
elif isinstance(spec, basestring):
|
||||||
assert isinstance(spec, basestring)
|
|
||||||
self.args = ()
|
self.args = ()
|
||||||
self.converter = getConverter(spec)
|
self.converter = getConverter(spec)
|
||||||
|
else:
|
||||||
|
assert isinstance(spec, context)
|
||||||
|
self.converter = spec
|
||||||
|
|
||||||
def __call__(self, irc, msg, args, state):
|
def __call__(self, irc, msg, args, state):
|
||||||
## if args and not (state.types or state.allowExtra):
|
## if args and not (state.types or state.allowExtra):
|
||||||
|
|
Loading…
Reference in New Issue