Skip to content

Commit

Permalink
[App] Minor improvment to error handling for...
Browse files Browse the repository at this point in the history
  • Loading branch information
Syres916 authored and donovaly committed Mar 21, 2023
1 parent bd1e29d commit cb21604
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/App/PropertyPythonObject.cpp
Expand Up @@ -121,6 +121,11 @@ void PropertyPythonObject::fromString(const std::string& repr)
try {
if (repr.empty())

Check warning on line 122 in src/App/PropertyPythonObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

statement should be inside braces [readability-braces-around-statements]
return;
if (repr == "null") {
Py::String typestr(this->object.type().str());
Base::Console().Log("PropertyPythonObject::fromString(): repr is null for object %s\n", typestr.as_string().c_str());
return;
}
Py::Module pickle(PyImport_ImportModule("json"),true);
if (pickle.isNull())

Check warning on line 130 in src/App/PropertyPythonObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

statement should be inside braces [readability-braces-around-statements]
throw Py::Exception();
Expand Down

0 comments on commit cb21604

Please sign in to comment.