refactor(系统设置): 优化保存配额报错空指针

This commit is contained in:
wxg0103 2023-10-10 11:23:00 +08:00 committed by 刘瑞斌
parent ce44ad18bd
commit cc24cbc7fb

View File

@ -79,7 +79,7 @@ public class QuotaManagementService {
quota.setResourcePool(String.join(",", intersection));
}
if (ObjectUtils.isNotEmpty(workspaceQuota) && ObjectUtils.isNotEmpty(quota) && StringUtils.isBlank(workspaceQuota.getModuleSetting())) {
if (ObjectUtils.isNotEmpty(workspaceQuota) && ObjectUtils.isNotEmpty(quota) && StringUtils.isNotBlank(workspaceQuota.getModuleSetting())) {
List<String> workModules = Arrays.asList(workspaceQuota.getModuleSetting().split(","));
List<String> projectModules = StringUtils.isNotBlank(quota.getModuleSetting()) ? Arrays.asList(quota.getModuleSetting().split(",")) : new ArrayList<>();
List<String> moduleIntersection = workModules.stream()