diff --git a/jsonrpc/__init__.py b/jsonrpc/__init__.py index e4d84b8..b4d8e2a 100644 --- a/jsonrpc/__init__.py +++ b/jsonrpc/__init__.py @@ -44,11 +44,8 @@ class Method: def __call__(self, query): if self.handler is None: return self.function() - def wrap(function): - # print(func) - return function - return wrap - return self.function() + result = self.handler(query, self.function) + return result class JSONRPC: @@ -160,7 +157,7 @@ class JSONRPC: try: if method.handler is None: method.handler( - query + query, method.function ) if params is None: