Skip to content

Commit 23b1462

Browse files
committed
construct empty exceptions with no arguments, instead of () and {}
1 parent bbf581e commit 23b1462

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

kazoo/exceptions.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -52,10 +52,7 @@ def _invalid_error_code():
5252

5353
def _zookeeper_exception(code):
5454
def decorator(klass):
55-
def create(*args, **kwargs):
56-
return klass(args, kwargs)
57-
58-
EXCEPTIONS[code] = create
55+
EXCEPTIONS[code] = klass
5956
klass.code = code
6057
return klass
6158

0 commit comments

Comments
 (0)