From 91c62966fac241adbaca52937cc6cad169504a7f Mon Sep 17 00:00:00 2001 From: Micheal Winger Date: Sat, 6 Aug 2016 23:56:24 -0400 Subject: [PATCH] /msg: Send SystemMsg confirmation with each PM --- host.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/host.go b/host.go index 21d799b..2ac1719 100644 --- a/host.go +++ b/host.go @@ -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 }, })