【fix sonar】SwitchProperty文件
This commit is contained in:
+2
-2
@@ -1,5 +1,6 @@
|
||||
package com.jero.common.util.jsonschema.validate;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.jero.common.util.jsonschema.CommonProperty;
|
||||
@@ -33,9 +34,8 @@ public class SwitchProperty extends CommonProperty {
|
||||
Map<String,Object> map = new HashMap<>();
|
||||
map.put("key",getKey());
|
||||
JSONObject prop = getCommonJson();
|
||||
JSONArray array = new JSONArray();
|
||||
if(extendStr!=null) {
|
||||
array = JSONArray.parseArray(extendStr);
|
||||
JSONArray array = JSON.parseArray(extendStr);
|
||||
prop.put("extendOption",array);
|
||||
}
|
||||
map.put("prop",prop);
|
||||
|
||||
Reference in New Issue
Block a user