mirror of
https://github.com/openimsdk/open-im-server.git
synced 2025-05-29 09:19:18 +08:00
test cron
This commit is contained in:
parent
0d46349386
commit
4989bb07f6
@ -82,6 +82,9 @@ func deleteMongoMsg(operationID string, ID string, index int64, delMsgIDList *[]
|
||||
}
|
||||
return getDelMaxSeqByIDList(*delMsgIDList), delMongoMsgs(operationID, delMsgIDList)
|
||||
}
|
||||
if index == 0 && msgs == nil {
|
||||
return 0, nil
|
||||
}
|
||||
if len(msgs.Msg) > db.GetSingleGocMsgNum() {
|
||||
log.NewWarn(operationID, utils.GetSelfFuncName(), "msgs too large", len(msgs.Msg), msgs.UID)
|
||||
}
|
||||
|
@ -277,7 +277,7 @@ func (d *DataBases) GetUserMsgListByIndex(ID string, index int64) (*UserChat, er
|
||||
if len(msgs) > 0 {
|
||||
return &msgs[0], err
|
||||
} else {
|
||||
return nil, errors.New("get msg list failed")
|
||||
return nil, nil
|
||||
}
|
||||
//return &msgs, nil
|
||||
}
|
||||
@ -317,7 +317,7 @@ func (d *DataBases) GetNewestMsg(ID string) (msg *MsgInfo, err error) {
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
err = cursor.Decode(&userChats)
|
||||
err = cursor.All(ctx, &userChats)
|
||||
if err != nil {
|
||||
return nil, utils.Wrap(err, "")
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user