[TD] Gui: remove some superfluous nullptr checks
This commit is contained in:
@@ -181,7 +181,7 @@ bool DrawGuiUtil::isDraftObject(App::DocumentObject* obj)
|
||||
bool result = false;
|
||||
App::PropertyPythonObject* proxy = dynamic_cast<App::PropertyPythonObject*>(obj->getPropertyByName("Proxy"));
|
||||
|
||||
if (proxy != nullptr) {
|
||||
if (proxy) {
|
||||
//if no proxy, can not be Draft obj
|
||||
//if has proxy, might be Draft obj
|
||||
std::stringstream ss;
|
||||
@@ -213,7 +213,7 @@ bool DrawGuiUtil::isArchObject(App::DocumentObject* obj)
|
||||
bool result = false;
|
||||
App::PropertyPythonObject* proxy = dynamic_cast<App::PropertyPythonObject*>(obj->getPropertyByName("Proxy"));
|
||||
|
||||
if (proxy != nullptr) {
|
||||
if (proxy) {
|
||||
//if no proxy, can not be Arch obj
|
||||
//if has proxy, might be Arch obj
|
||||
Py::Object proxyObj = proxy->getValue();
|
||||
@@ -243,7 +243,7 @@ bool DrawGuiUtil::isArchSection(App::DocumentObject* obj)
|
||||
bool result = false;
|
||||
App::PropertyPythonObject* proxy = dynamic_cast<App::PropertyPythonObject*>(obj->getPropertyByName("Proxy"));
|
||||
|
||||
if (proxy != nullptr) {
|
||||
if (proxy) {
|
||||
//if no proxy, can not be Arch obj
|
||||
//if has proxy, might be Arch obj
|
||||
Py::Object proxyObj = proxy->getValue();
|
||||
|
||||
Reference in New Issue
Block a user