tree data helpers REFACTOR redundant condition
diff --git a/src/tree_data_helpers.c b/src/tree_data_helpers.c
index 90b1434..90d6164 100644
--- a/src/tree_data_helpers.c
+++ b/src/tree_data_helpers.c
@@ -574,7 +574,7 @@
     snode = lys_find_child(parent ? parent->schema : NULL, mod, opaq->name.name, 0, 0, 0);
     if (!snode && parent && parent->schema && (parent->schema->nodetype & (LYS_RPC | LYS_ACTION))) {
         /* maybe output node */
-        snode = lys_find_child(parent ? parent->schema : NULL, mod, opaq->name.name, 0, 0, LYS_GETNEXT_OUTPUT);
+        snode = lys_find_child(parent->schema, mod, opaq->name.name, 0, 0, LYS_GETNEXT_OUTPUT);
     }
     if (!snode) {
         if (parent) {