From 8ac1794853cafdf46ec65144707a7278490e5b68 Mon Sep 17 00:00:00 2001 From: Tim Date: Tue, 5 Aug 2025 10:38:36 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=20=E4=BA=92=E5=8A=A8=E5=85=88=E5=8F=96?= =?UTF-8?q?=E6=B6=88=E9=80=9A=E7=9F=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/openisle/service/ReactionService.java | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/backend/src/main/java/com/openisle/service/ReactionService.java b/backend/src/main/java/com/openisle/service/ReactionService.java index 9e162bd03..ae336bad9 100644 --- a/backend/src/main/java/com/openisle/service/ReactionService.java +++ b/backend/src/main/java/com/openisle/service/ReactionService.java @@ -49,15 +49,6 @@ public class ReactionService { reaction = reactionRepository.save(reaction); if (!user.getId().equals(post.getAuthor().getId())) { notificationService.createNotification(post.getAuthor(), NotificationType.REACTION, post, null, null, user, type, null); - - long count = reactionRepository.countReceived(post.getAuthor().getUsername()); - if (count % 5 == 0) { - String url = websiteUrl + "/messages"; - notificationService.sendCustomPush(post.getAuthor(), "你有新的互动", url); - if (post.getAuthor().getEmail() != null) { - emailSender.sendEmail(post.getAuthor().getEmail(), "你有新的互动", url); - } - } } return reaction; } @@ -82,15 +73,6 @@ public class ReactionService { reaction = reactionRepository.save(reaction); if (!user.getId().equals(comment.getAuthor().getId())) { notificationService.createNotification(comment.getAuthor(), NotificationType.REACTION, comment.getPost(), comment, null, user, type, null); - - long count = reactionRepository.countReceived(comment.getAuthor().getUsername()); - if (count % 5 == 0) { - String url = websiteUrl + "/messages"; - notificationService.sendCustomPush(comment.getAuthor(), "你有新的互动", url); - if (comment.getAuthor().getEmail() != null) { - emailSender.sendEmail(comment.getAuthor().getEmail(), "你有新的互动", url); - } - } } return reaction; }