优化指令,防止骚扰。只发给自己
This commit is contained in:
6
robot.py
6
robot.py
@@ -299,8 +299,10 @@ class Robot(Job):
|
||||
if msg.from_self():
|
||||
self.revoke_receive_message(msg)
|
||||
rsp = self.gbm.handle_command(msg.roomid, msg.content)
|
||||
self.send_text_msg(rsp, msg.roomid, msg.sender)
|
||||
return
|
||||
# 不在群里发送,防止被骚扰
|
||||
if rsp is not None:
|
||||
self.send_text_msg(rsp, msg.sender)
|
||||
return
|
||||
except Exception as e:
|
||||
self.LOG.error(f"revoke_receive_message error: {e}")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user