Remove definitions from OpenApiObject
[netconf.git] / restconf / sal-rest-docgen / src / main / java / org / opendaylight / netconf / sal / rest / doc / mountpoints / MountPointOpenApi.java
index 1478124e913f2b0b128c2d03a73ee8ea335687a4..053fca881e838c1044c08dde681116aee1bde845 100644 (file)
@@ -186,7 +186,7 @@ public class MountPointOpenApi implements DOMMountPointListener, AutoCloseable {
         if (includeDataStore) {
             doc = generateDataStoreApiDoc(uriInfo, urlPrefix, deviceName);
             addFields(doc.getPaths() ,openApiObject.getPaths().fields());
-            addFields(doc.getDefinitions() ,openApiObject.getDefinitions().fields());
+            addFields(doc.getComponents().getSchemas(), openApiObject.getComponents().getSchemas().fields());
             doc.getInfo().setTitle(openApiObject.getInfo().getTitle());
         } else {
             doc = openApiObject;
@@ -215,7 +215,6 @@ public class MountPointOpenApi implements DOMMountPointListener, AutoCloseable {
                 context, deviceName, pathsObject);
 
         declaration.setPaths(pathsObject);
-        declaration.setDefinitions(JsonNodeFactory.instance.objectNode());
 
         return declaration;
     }