From 60966044b10db4188fedf66ef57f1b2861b2338c Mon Sep 17 00:00:00 2001 From: Jeremy Fincher Date: Thu, 28 Oct 2004 17:08:23 +0000 Subject: [PATCH] This should allow contexts where we allow converters. --- src/commands.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/commands.py b/src/commands.py index 6d1bc1f11..ced166cc1 100644 --- a/src/commands.py +++ b/src/commands.py @@ -601,10 +601,12 @@ class context(object): self.converter = getConverter(spec[0]) elif spec is None: self.converter = getConverter('anything') - else: - assert isinstance(spec, basestring) + elif isinstance(spec, basestring): self.args = () self.converter = getConverter(spec) + else: + assert isinstance(spec, context) + self.converter = spec def __call__(self, irc, msg, args, state): ## if args and not (state.types or state.allowExtra):