This commit is contained in:
Michael Droettboom 2015-09-16 06:43:16 -04:00
parent a0cefb3213
commit 859259ddae
1 changed files with 1 additions and 1 deletions

View File

@ -37,7 +37,7 @@ if hasattr(inspect, 'signature'):
def _has_positional_arg(func):
sig = inspect.signature(func)
params = list(sig.parameters.values())
if len(params):
if params:
return params[0].kind in (sig.POSITIONAL_ONLY, sig.POSITIONAL_OR_KEYWORD)
else:
return False