From 6a553f11e8323af317bdab963e47756f2e57694f Mon Sep 17 00:00:00 2001 From: wh_zcy Date: Thu, 22 Dec 2022 23:56:40 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=88=A0=E9=99=A4?= =?UTF-8?q?=E5=85=83=E7=B4=A0=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/sociaty/model_sociaty.go | 17 ++++++++++------- modules/task/model_active.go | 5 +++-- 2 files changed, 13 insertions(+), 9 deletions(-) diff --git a/modules/sociaty/model_sociaty.go b/modules/sociaty/model_sociaty.go index 4dc4b8323..d445f577e 100644 --- a/modules/sociaty/model_sociaty.go +++ b/modules/sociaty/model_sociaty.go @@ -352,9 +352,10 @@ func (this *ModelSociaty) updateSociaty(sociatyId string, update map[string]inte // 退出公会 func (this *ModelSociaty) quit(uid string, sociaty *pb.DBSociaty) error { - for i, m := range sociaty.Members { - if m.Uid == uid { + for i:=0;i Date: Fri, 23 Dec 2022 10:00:51 +0800 Subject: [PATCH 2/2] update --- modules/hunting/model_hunting.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/modules/hunting/model_hunting.go b/modules/hunting/model_hunting.go index b25d35e93..f610a87ed 100644 --- a/modules/hunting/model_hunting.go +++ b/modules/hunting/model_hunting.go @@ -3,7 +3,6 @@ package hunting import ( "go_dreamfactory/comm" "go_dreamfactory/lego/core" - "go_dreamfactory/lego/sys/mgo" "go_dreamfactory/modules" "go_dreamfactory/pb" @@ -34,7 +33,7 @@ func (this *modelHunting) modifyHuntingDataByObjId(uid string, data map[string]i // 获取列表信息 func (this *modelHunting) getHuntingList(uid string) (result *pb.DBHunting, err error) { result = &pb.DBHunting{} - if err = this.Get(uid, result); err != nil && mgo.MongodbNil != err { + if err = this.Get(uid, result); err != nil { return }