- const char *omit = atts.getValue("omit-node");
- if (omit && !strcmp(omit, "y")) {
- int nChildren = node->nChildren();
- for (int i = 0; i < nChildren; i++) {
- SGPropertyNode *src = node->getChild(i);
- const char *name = src->getName();
- int index = st.counters[name];
- st.counters[name]++;
- SGPropertyNode *dst = st.node->getChild(name, index, true);
- copyProperties(src, dst);
- }
- st.node->removeChild(node->getName(), node->getIndex(), false);
- node = st.node;
- }
+ attval = atts.getValue("omit-node");
+ omit = checkFlag(attval, false);