tree data helpers REFACTOR redundant condition
@@ -574,7 +574,7 @@ lyd_parse_opaq_error(const struct lyd_node *node)
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) {
