fix(接口测试): 修复导入部分postman文件报错问题

This commit is contained in:
guoyuqi 2023-02-01 10:48:13 +08:00 committed by xiaomeinvG
parent 646881e736
commit f73576785f
1 changed files with 5 additions and 1 deletions

View File

@ -140,7 +140,11 @@ public abstract class PostmanAbstractParserParser<T> extends ApiImportAbstractPa
if (postmanBody == null) {
return;
}
String bodyMode = postmanBody.get("mode").textValue();
String bodyMode = null;
if (postmanBody.has("mode")) {
bodyMode = postmanBody.get("mode").textValue();
}
if (StringUtils.isBlank(bodyMode)) {
return;
}