From 076b9857160583965c9c57bfee2d62b808b3046a Mon Sep 17 00:00:00 2001 From: Chris Sexton Date: Tue, 7 May 2013 19:05:40 -0400 Subject: [PATCH] Adding the bot to its own list of users. (future usage) --- bot/bot.go | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/bot/bot.go b/bot/bot.go index 43fd276..5c427ee 100644 --- a/bot/bot.go +++ b/bot/bot.go @@ -117,11 +117,18 @@ func NewBot(config *config.Config, c *irc.Conn) *Bot { config.Nick = c.Me.Nick + users := []User{ + User{ + Name: config.Nick, + MessageLog: make([]string, 0), + }, + } + return &Bot{ Config: config, Plugins: make(map[string]Handler), PluginOrdering: make([]string, 0), - Users: make([]User, 0), + Users: users, Conn: c, DbSession: session, Db: db,