Forgot to add the API object
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Hamcha 2019-06-27 17:12:39 +02:00
parent 19c4b42bf4
commit 4f3ad1d63a
2 changed files with 2 additions and 1 deletions

View file

@ -27,6 +27,7 @@ type BotInterface interface {
func newDraftBot(botAPI BotInterface, name string) *draftBot { func newDraftBot(botAPI BotInterface, name string) *draftBot {
return &draftBot{ return &draftBot{
API: botAPI,
Name: name, Name: name,
Sessions: make(map[string]session), Sessions: make(map[string]session),
} }

View file

@ -82,7 +82,7 @@ func runBot(name string, games, tags []string) error {
} }
draftbot := newDraftBot(wsbot, name) draftbot := newDraftBot(wsbot, name)
wsbot.Listen(draftbot.onMessage) wsbot.Listen(draftbot.onMessage)
return errors.New("eof") return errors.New("eof")
} }