From 3d150d8ae51e8b8008d7eb27591cff67e467b46d Mon Sep 17 00:00:00 2001 From: Christophe de Vienne Date: Thu, 13 Oct 2011 13:53:02 +0200 Subject: [PATCH] WSRoot.addprotocol now takes keywords parameters and transmit them to getprotocol for instanciating the protocol --- wsme/controller.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wsme/controller.py b/wsme/controller.py index 592c50a..b6d2660 100644 --- a/wsme/controller.py +++ b/wsme/controller.py @@ -225,7 +225,7 @@ class WSRoot(object): self._api = None - def addprotocol(self, protocol): + def addprotocol(self, protocol, **options): """ Enable a new protocol on the controller. @@ -233,7 +233,7 @@ class WSRoot(object): of a protocol. """ if isinstance(protocol, str): - protocol = getprotocol(protocol) + protocol = getprotocol(protocol, options) self.protocols[protocol.name] = protocol protocol.root = weakref.proxy(self)