diff --git a/dtool/src/interrogate/interfaceMakerPythonNative.cxx b/dtool/src/interrogate/interfaceMakerPythonNative.cxx index 163ece8030..0606965fa3 100644 --- a/dtool/src/interrogate/interfaceMakerPythonNative.cxx +++ b/dtool/src/interrogate/interfaceMakerPythonNative.cxx @@ -3814,7 +3814,7 @@ write_function_for_name(ostream &out, Object *obj, // None of the remaps take any keyword arguments, so let's check that // we take none. This saves some checks later on. indent(out, 4) << "if (kwds == nullptr || PyDict_GET_SIZE(kwds) == 0) {\n"; - if (min_args == 1 && min_args == 1) { + if (min_args == 1 && max_args == 1) { indent(out, 4) << " PyObject *arg = PyTuple_GET_ITEM(args, 0);\n"; always_returns = write_function_forset(out, mii->second, min_args, max_args, expected_params, 6,