From 0edab788f512d3c269c6b5caa62682dc1ef396f4 Mon Sep 17 00:00:00 2001
From: DESKTOP-71BH0QO\L、ming <172680469@qq.com>
Date: 星期二, 30 三月 2021 18:04:20 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'

---
 springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComMngStructOtherBuildServiceImpl.java |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComMngStructOtherBuildServiceImpl.java b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComMngStructOtherBuildServiceImpl.java
index 16a1d24..a598a7f 100644
--- a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComMngStructOtherBuildServiceImpl.java
+++ b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComMngStructOtherBuildServiceImpl.java
@@ -135,7 +135,9 @@
         buildTypdIds.forEach(aLong -> {
             if (!collect.contains(aLong)) {
                 ComMngStructBuildTypeDO comMngStructBuildTypeDO = comMngStructBuildTypeDAO.selectById(aLong);
-                throw new ServiceException(comMngStructBuildTypeDO.getName()+"已经在使用无法删除");
+                if (!ObjectUtils.isEmpty(comMngStructBuildTypeDO)) {
+                    throw new ServiceException(comMngStructBuildTypeDO.getName()+"已经在使用无法删除");
+                }
             }
         });
          comMngStructBuildTypeDAO.delete(new QueryWrapper<ComMngStructBuildTypeDO>().lambda().eq(ComMngStructBuildTypeDO::getCommunityId, communityId));

--
Gitblit v1.7.1