diff options
author | Michele Simionato <michele.simionato@gmail.com> | 2021-05-28 08:30:09 +0200 |
---|---|---|
committer | Michele Simionato <michele.simionato@gmail.com> | 2021-05-28 08:30:09 +0200 |
commit | 817d070db3c9cc5900d118837c533c039982b050 (patch) | |
tree | 8f5d0e81c49b278c5ced5e76785c7ea6343d2986 | |
parent | 31161d2e51b3411aa24bd48f05f1f75ccfaaecbb (diff) | |
download | python-decorator-git-817d070db3c9cc5900d118837c533c039982b050.tar.gz |
Fixed decorator.decorator not passing kwsyntax
-rw-r--r-- | CHANGES.md | 2 | ||||
-rw-r--r-- | src/decorator.py | 2 |
2 files changed, 3 insertions, 1 deletions
@@ -3,6 +3,8 @@ HISTORY ## unreleased +decorator.decorator was not passing the kwsyntax. + ## 5.0.9 (2021-05-16) Fixed a test breaking PyPy. Restored support for Sphinx. diff --git a/src/decorator.py b/src/decorator.py index 438dff6..dab0d7c 100644 --- a/src/decorator.py +++ b/src/decorator.py @@ -265,7 +265,7 @@ def decorator(caller, _func=None, kwsyntax=False): """ if _func is not None: # return a decorated function # this is obsolete behavior; you should use decorate instead - return decorate(_func, caller) + return decorate(_func, caller, (), kwsyntax) # else return a decorator function sig = inspect.signature(caller) dec_params = [p for p in sig.parameters.values() if p.kind is POS] |