提交 95aeee54 authored 作者: YunaiV's avatar YunaiV

修复配置不可见时,返回 null 的问题

上级 1dbcf4ad
......@@ -73,7 +73,7 @@ public class ConfigController {
public CommonResult<String> getConfigKey(@RequestParam("key") String key) {
ConfigDO config = configService.getConfigByKey(key);
if (config == null) {
return null;
return success(null);
}
if (!config.getVisible()) {
throw exception(ErrorCodeConstants.CONFIG_GET_VALUE_ERROR_IF_VISIBLE);
......@@ -102,4 +102,4 @@ public class ConfigController {
ExcelUtils.write(response, "参数配置.xls", "数据", ConfigExcelVO.class, datas);
}
}
\ No newline at end of file
}
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论