diff --git a/db/db_user.go b/db/db_user.go index 8d445a6..4b3df89 100644 --- a/db/db_user.go +++ b/db/db_user.go @@ -8,7 +8,7 @@ import ( // UserFindByMobile search user by mobile func UserFindByMobile(Db *xorm.Engine, mobile string) (*model.User, error) { var m model.User - if has, err := Db.Where("phone = ? AND delete_at = 0", mobile, mobile). + if has, err := Db.Where("phone = ? AND delete_at = 0", mobile). Get(&m); err != nil || has == false { return nil, err }