Commit f9e90661 authored by chenjianxing's avatar chenjianxing
Browse files

fix: 接口导入MS格式报空指针

No related merge requests found
Showing with 2 additions and 2 deletions
+2 -2
......@@ -97,7 +97,7 @@ public class MsScenarioParser extends MsAbstractParser<ScenarioImport> {
}
}
if (finalNodeMap != null) {
if (finalNodeMap != null && finalNodeMap.get(item.getApiScenarioModuleId()) != null) {
NodeTree node = finalNodeMap.get(item.getApiScenarioModuleId());
item.setApiScenarioModuleId(node.getNewId());
item.setModulePath(node.getPath());
......
......@@ -106,7 +106,7 @@ public class MsDefinitionParser extends MsAbstractParser<ApiDefinitionImport> {
String originId = apiDefinition.getId();
String id = UUID.randomUUID().toString();
if (nodeMap != null) {
if (nodeMap != null && nodeMap.get(apiDefinition.getModuleId()) != null) {
NodeTree nodeTree = nodeMap.get(apiDefinition.getModuleId());
apiDefinition.setModuleId(nodeTree.getNewId());
apiDefinition.setModulePath(nodeTree.getPath());
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment