|
@@ -68,7 +68,7 @@ public class WebTenantGatewayImpl implements WebTenantGateway {
|
|
|
} else {
|
|
|
|
|
|
List<TblTenant> tenantList = tblTenantService.queryByCodeOrName(req.getTenantCode(), req.getTenantName());
|
|
|
- if (CollectionUtils.isEmpty(tenantList) || tenantList.size() > 2 || !tenantList.get(0).getTenantId().equals(req.getTenantId())) {
|
|
|
+ if ((!CollectionUtils.isEmpty(tenantList) && tenantList.size() > 2) || !tenantList.get(0).getTenantId().equals(req.getTenantId())) {
|
|
|
throw new BizException(ErrorEnum.TENANT_IS_ALREADY_EXIST.getErrorCode(), ErrorEnum.TENANT_IS_ALREADY_EXIST.getErrorMessage());
|
|
|
}
|
|
|
// 更新租户
|