This commit is contained in:
shoopea 2020-01-14 10:38:42 +08:00
parent 80a86a1c6e
commit 817b086738
2 changed files with 4 additions and 3 deletions

View File

@ -5,13 +5,11 @@ package main
import (
"database/sql"
"flag"
"fmt"
"log"
"math/rand"
"sync"
"time"
"gopkg.in/gcfg.v1"
//"github.com/robfig/cron/v3"
"gopkg.in/robfig/cron.v3"

View File

@ -1,11 +1,14 @@
package main
import (
"encoding/json"
"errors"
"log"
"regexp"
"strconv"
"time"
tb "gopkg.in/tucnak/telebot.v2"
)
func failOnError(err error, msg string) {
@ -37,7 +40,7 @@ func MaxInt(a int, b int) int {
}
func PrintText(m *tb.Message) {
fmt.Printf("[%d] %s(%d) | %s(%d) : %s\n", m.ID, m.Chat.Title, m.Chat.ID, m.Sender.Username, m.Sender.ID, m.Text)
log.Printf("[%d] %s(%d) | %s(%d) : %s\n", m.ID, m.Chat.Title, m.Chat.ID, m.Sender.Username, m.Sender.ID, m.Text)
return
}