Merge f346fa737aee3b711bf4827923f9583a90e228b9 into a978f2ce006f41369f03105fa98defda45fbb10b

This commit is contained in:
The8BitGuy42 2016-08-03 19:24:40 +00:00 committed by GitHub
commit 678ad50b0f

13
host.go
View File

@ -422,7 +422,7 @@ func (h *Host) InitCommands(c *chat.Commands) {
c.Add(chat.Command{
Op: true,
Prefix: "/motd",
Prefix: "/setmotd",
PrefixHelp: "MESSAGE",
Help: "Set the MESSAGE of the day.",
Handler: func(room *chat.Room, msg message.CommandMsg) error {
@ -446,6 +446,17 @@ func (h *Host) InitCommands(c *chat.Commands) {
return nil
},
})
c.Add(chat.Command{
Prefix: "/motd",
Help: "Display the MESSAGE of the day.",
Handler: func(room *chat.Room, msg message.CommandMsg) error {
room.Send(message.NewAnnounceMsg(h.motd))
return nil
},
})
c.Add(chat.Command{
Op: true,