fix(项目设置): 自定义代码片段执行报错

--bug=1018680 --user=李玉号
【项目设置】自定义代码片段-创建代码片段-从API定义导入-测试-执行结果报错
https://www.tapd.cn/55049933/s/1273843
This commit is contained in:
shiziyuan9527 2022-10-24 11:14:54 +08:00 committed by lyh
parent c41335d4af
commit ee5b5e77c2
1 changed files with 3 additions and 0 deletions

View File

@ -281,6 +281,9 @@ function _beanshellTemplate(obj) {
}
try {
requestBody = JSON.stringify(requestBody);
if (!requestBody || requestBody === "null") {
requestBody = "";
}
} catch (e) {
requestBody = "";
}