mirror of
https://github.com/shazow/ssh-chat.git
synced 2026-11-28 03:32:25 +03:00
/msg: Send SystemMsg confirmation with each PM
This commit is contained in:
1 parent
66adee6f9a
commit
91c62966fa
1 file changed
+8
@@ -288,6 +288,10 @@ func (h *Host) InitCommands(c *chat.Commands) {
|
||||
|
||||
m := message.NewPrivateMsg(strings.Join(args[1:], " "), msg.From(), target)
|
||||
room.Send(&m)
|
||||
|
||||
txt := fmt.Sprintf("[Sent PM to %s]", target.Name())
|
||||
ms := message.NewSystemMsg(txt, msg.From())
|
||||
room.Send(ms)
|
||||
return nil
|
||||
},
|
||||
})
|
||||
@@ -310,6 +314,10 @@ func (h *Host) InitCommands(c *chat.Commands) {
|
||||
|
||||
m := message.NewPrivateMsg(strings.Join(args, " "), msg.From(), target)
|
||||
room.Send(&m)
|
||||
|
||||
txt := fmt.Sprintf("[Sent PM to %s]", target.Name())
|
||||
ms := message.NewSystemMsg(txt, msg.From())
|
||||
room.Send(ms)
|
||||
return nil
|
||||
},
|
||||
})
|
||||
|
||||
Reference in new issue
Block a user