Use QName.withModule()
[mdsal.git] / binding / mdsal-binding-generator-impl / src / main / java / org / opendaylight / mdsal / binding / generator / impl / BindingSchemaContextUtils.java
index 68c2dd18d6c4a3dee5ca2d6be2568e6caf54d3e5..497d98a965e4aac59d36eced0164be404b34b80e 100644 (file)
@@ -73,7 +73,7 @@ public final class BindingSchemaContextUtils {
             if(ChildOf.class.isAssignableFrom(currentArg.getType()) && BindingReflections.isAugmentationChild(currentArg.getType())) {
                 currentQName = BindingReflections.findQName(currentArg.getType());
             } else {
-                currentQName = QName.create(currentQName, BindingReflections.findQName(currentArg.getType()).getLocalName());
+                currentQName = BindingReflections.findQName(currentArg.getType()).withModule(currentQName.getModule());
             }
             Optional<DataNodeContainer> potential = findDataNodeContainer(currentContainer.get(), currentQName);
             if (potential.isPresent()) {