File tree 1 file changed +4
-4
lines changed 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -1610,17 +1610,17 @@ def param(func):
1610
1610
if not python_has_signature :
1611
1611
arg_spec = inspect .getargspec (func )
1612
1612
_arg_names = arg_spec .args
1613
- _has_no_varargs = arg_spec .varargs is None
1613
+ _has_varargs = arg_spec .varargs is not None
1614
1614
_has_varkwargs = arg_spec .keywords is not None
1615
1615
else :
1616
1616
sig = signature (func )
1617
- _has_no_varargs = True
1617
+ _has_varargs = False
1618
1618
_has_varkwargs = False
1619
1619
_arg_names = []
1620
1620
params = list (sig .parameters .values ())
1621
1621
for p in params :
1622
1622
if p .kind is Parameter .VAR_POSITIONAL :
1623
- _has_no_varargs = False
1623
+ _has_varargs = True
1624
1624
elif p .kind is Parameter .VAR_KEYWORD :
1625
1625
_has_varkwargs = True
1626
1626
else :
@@ -1639,7 +1639,7 @@ def param(func):
1639
1639
# positional args can end up in **kwargs, so only *varargs make
1640
1640
# problems.
1641
1641
# http://stupidpythonideas.blogspot.de/2013/08/arguments-and-parameters.html
1642
- if _has_no_varargs :
1642
+ if not _has_varargs :
1643
1643
# all args are "named", so no problem
1644
1644
# remove the first "ax" / self arg
1645
1645
arg_names = _arg_names [1 :]
You can’t perform that action at this time.
0 commit comments