From 5026dac65fa110b22a4d079692b4084d536f162e Mon Sep 17 00:00:00 2001 From: heavyrian2012 Date: Sun, 25 Feb 2024 09:23:26 +0800 Subject: [PATCH] =?UTF-8?q?=E6=AF=8F=E6=AC=A1=E7=99=BB=E5=BD=95=E7=9A=84?= =?UTF-8?q?=E6=97=B6=E5=80=99=E9=83=BD=E5=8F=91=E9=80=81=E6=9C=BA=E5=99=A8?= =?UTF-8?q?=E4=BA=BA=E6=AC=A2=E8=BF=8E=E8=AF=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/cn/wildfirechat/app/ServiceImpl.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/main/java/cn/wildfirechat/app/ServiceImpl.java b/src/main/java/cn/wildfirechat/app/ServiceImpl.java index e605d89..6d0cbd7 100644 --- a/src/main/java/cn/wildfirechat/app/ServiceImpl.java +++ b/src/main/java/cn/wildfirechat/app/ServiceImpl.java @@ -596,9 +596,9 @@ private RestResult onLoginSuccess(HttpServletResponse httpResponse, String mobil if (mIMConfig.new_user_robot_friend && !StringUtils.isEmpty(mIMConfig.robot_friend_id)) { RelationAdmin.setUserFriend(user.getUserId(), mIMConfig.robot_friend_id, true, null); - if (!StringUtils.isEmpty(mIMConfig.robot_welcome)) { - sendTextMessage(mIMConfig.robot_friend_id, user.getUserId(), mIMConfig.robot_welcome); - } + } + if (!StringUtils.isEmpty(mIMConfig.robot_welcome)) { + sendTextMessage(mIMConfig.robot_friend_id, user.getUserId(), mIMConfig.robot_welcome); } if (!StringUtils.isEmpty(mIMConfig.new_user_subscribe_channel_id)) { @@ -612,6 +612,9 @@ private RestResult onLoginSuccess(HttpServletResponse httpResponse, String mobil if (!StringUtils.isEmpty(mIMConfig.welcome_for_back_user)) { sendTextMessage(mIMConfig.admin_user_id, user.getUserId(), mIMConfig.welcome_for_back_user); } + if (!StringUtils.isEmpty(mIMConfig.robot_welcome)) { + sendTextMessage(mIMConfig.robot_friend_id, user.getUserId(), mIMConfig.robot_welcome); + } if (!StringUtils.isEmpty(mIMConfig.back_user_subscribe_channel_id)) { try { IMResult booleanValueIMResult = GeneralAdmin.isUserSubscribedChannel(user.getUserId(), mIMConfig.getBack_user_subscribe_channel_id());