Skip to content

Commit d3e65a6

Browse files
committed
fix: update plugify
1 parent 58dbac9 commit d3e65a6

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

src/module.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3106,20 +3106,20 @@ namespace py3lm {
31063106
}
31073107
}
31083108

3109-
PyObject* AliasToTuple(const Alias& alias) {
3110-
if (alias.GetName().empty()) {
3109+
PyObject* AliasToTuple(const std::optional<Alias>& alias) {
3110+
if (!alias) {
31113111
return CreatePyObject();
31123112
}
31133113

31143114
PyObject* tuple = PyTuple_New(Py_ssize_t{ 2 });
31153115
if (!tuple) return nullptr;
31163116

3117-
PyObject* name = CreatePyObject(alias.GetName());
3117+
PyObject* name = CreatePyObject(alias->GetName());
31183118
if (!name) {
31193119
Py_DECREF(tuple);
31203120
return nullptr;
31213121
}
3122-
PyObject* owner = CreatePyObject(alias.IsOwner());
3122+
PyObject* owner = CreatePyObject(alias->IsOwner());
31233123
if (!owner) {
31243124
Py_DECREF(tuple);
31253125
return nullptr;

0 commit comments

Comments
 (0)