Commit f9c01b08 authored by Antoine Millet's avatar Antoine Millet
Browse files

Fixed bug in simplerpcclient with default handler.

parent bb904cd6
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -21,6 +21,7 @@ class SimpleRpcClient(ConnectionManager):
        
        self._on_disconnect = on_disconnect
        self._connection = connection
        self._connection.set_handler(default_handler)
        self.register(self._connection)

    @classmethod
@@ -45,7 +46,8 @@ class SimpleRpcClient(ConnectionManager):

        connection = RpcConnection.from_addr(addr, port, None,
                                             enable_ssl=enable_ssl, cert=cert)
        client = cls(connection, default_handler, on_disconnect)
        client = cls(connection, default_handler=default_handler,
                     on_disconnect=on_disconnect)
        connection._manager = client
        return client