diff --git a/main.go b/main.go index f1d9afc..75156a9 100644 --- a/main.go +++ b/main.go @@ -105,12 +105,12 @@ func main() { ownUserID64 = int64(OwnUserID(client)) if *history { + fmt.Printf("Retrieving chat.\n") go getHistory(client) } - go ListenCW(client) - fmt.Println("Started !") + go ListenCW(client) // Main loop for { diff --git a/td.go b/td.go index 85e9bf3..47357c2 100644 --- a/td.go +++ b/td.go @@ -108,8 +108,6 @@ func getHistory(c *tdlib.Client) { var msgCount int32 = 0 var lastMsgTime time.Time = time.Now() - fmt.Printf("Retrieving chat.\n") - conn, err := amqp.Dial("amqp://" + cfg.Rabbit.User + ":" + cfg.Rabbit.Password + "@" + cfg.Rabbit.Host + "/" + cfg.Rabbit.Queue) if err != nil { log.Fatal(err)