|
|
@@ -2209,7 +2209,7 @@ write_module_class(ostream &out, Object *obj) {
|
|
|
|
|
|
string expected_params;
|
|
|
|
|
|
- out << " if (arg2 != (PyObject *)NULL) {\n";
|
|
|
+ out << " if (arg2 != (PyObject *)NULL && arg2 != Py_None) {\n";
|
|
|
out << " PyObject *args = PyTuple_Pack(2, arg, arg2);\n";
|
|
|
write_function_forset(out, two_param_remaps, 2, 2, expected_params, 4,
|
|
|
true, true, AT_varargs, RF_pyobject | RF_err_null | RF_decref_args, true);
|