This is an automated email from the ASF dual-hosted git repository.

xiaoyu pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/shenyu.git


The following commit(s) were added to refs/heads/master by this push:
     new af0444f5d [type:bugfix] fixed shenyu-admin rule (#4210)
af0444f5d is described below

commit af0444f5d6efabedc565b29f7a7384b4e79f3fc7
Author: 愿凌飞 <[email protected]>
AuthorDate: Fri Nov 25 15:21:19 2022 +0800

    [type:bugfix] fixed shenyu-admin rule (#4210)
    
    Co-authored-by: likeguo <[email protected]>
---
 .../main/java/org/apache/shenyu/admin/service/impl/RuleServiceImpl.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/shenyu-admin/src/main/java/org/apache/shenyu/admin/service/impl/RuleServiceImpl.java
 
b/shenyu-admin/src/main/java/org/apache/shenyu/admin/service/impl/RuleServiceImpl.java
index f3bac974b..756dbf15b 100644
--- 
a/shenyu-admin/src/main/java/org/apache/shenyu/admin/service/impl/RuleServiceImpl.java
+++ 
b/shenyu-admin/src/main/java/org/apache/shenyu/admin/service/impl/RuleServiceImpl.java
@@ -217,9 +217,9 @@ public class RuleServiceImpl implements RuleService {
     public int delete(final List<String> ids) {
         List<RuleDO> rules = ruleMapper.selectByIds(ids);
         final int deleteCount = ruleMapper.deleteByIds(ids);
-        ruleConditionMapper.deleteByRuleIds(ids);
         if (deleteCount > 0) {
             ruleEventPublisher.onDeleted(rules);
+            ruleConditionMapper.deleteByRuleIds(ids);
         }
         return deleteCount;
     }

Reply via email to