This commit is contained in:
iyear 2020-03-27 21:46:03 +08:00
parent 92145684d7
commit 7255e605d5
2 changed files with 2 additions and 6 deletions

View File

@ -68,8 +68,8 @@ func DelData(db *sql.DB, refreshToken string) (bool, error) {
}
//query data by tg_id
func QueryData(db *sql.DB, tgid int) []MSData {
rows, err := db.Query("select * from users where tg_id = ?", tgid)
func QueryData(db *sql.DB, tgId int64) []MSData {
rows, err := db.Query("select * from users where tg_id = ?", tgId)
CheckErr(err)
var result = make([]MSData, 0)
defer rows.Close()

View File

@ -8,10 +8,6 @@ import (
"strings"
)
const (
bStartContent string = "欢迎使用E5SubBot!"
)
func CheckErr(err error) bool {
if err != nil {
log.Println(err)