From d2e8939f2c9736bbe6d3f7d9a4a7170ffc62e06f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=96=B9=E6=9F=B3=E7=85=9C?= <101934327+fangliuyu@users.noreply.github.com> Date: Tue, 19 Jul 2022 22:12:43 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E7=BE=A4=E8=80=81=E5=A9=86?= =?UTF-8?q?=E9=97=B9=E7=A6=BB=E5=A9=9A=E6=88=90=E5=8A=9F=E4=BD=86=E5=AE=9E?= =?UTF-8?q?=E9=99=85=E6=B2=A1=E7=A6=BB=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- plugin/qqwife/qqmapwife.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/plugin/qqwife/qqmapwife.go b/plugin/qqwife/qqmapwife.go index 35461cc60c..3392bfe1ce 100644 --- a/plugin/qqwife/qqmapwife.go +++ b/plugin/qqwife/qqmapwife.go @@ -123,7 +123,7 @@ func (sql *婚姻登记) 离婚休夫(gid, husband int64) error { gidstr := strconv.FormatInt(gid, 10) husbandstr := strconv.FormatInt(husband, 10) // 先判断用户是否存在 - err := sql.db.Del(gidstr, "where target = "+husbandstr) + err := sql.db.Del(gidstr, "where user = "+husbandstr) return err } @@ -135,10 +135,10 @@ func (sql *婚姻登记) 复婚(gid, uid, target int64, username, targetname str tagstr := strconv.FormatInt(target, 10) var info userinfo err := sql.db.Find(gidstr, &info, "where user = "+uidstr) - if err == nil { + if err != nil { err = sql.db.Find(gidstr, &info, "where user = "+tagstr) } - if err == nil { + if err != nil { return err } updatetime := time.Now().Format("2006/01/02")