add new tests and fix small bugs

This commit is contained in:
Yuli
2020-02-15 18:35:51 +02:00
parent 5179fea061
commit 7847a293ad
5 changed files with 88 additions and 25 deletions

View File

@@ -100,6 +100,9 @@ func (dbobj dbcon) getAuditEvents(userTOKEN string, offset int32, limit int32) (
if err != nil {
return nil, 0, err
}
if count == 0 {
return []byte("[]"), 0, err
}
var results []bson.M
records, err := dbobj.getList(TblName.Audit, "record", userTOKEN, offset, limit)
if err != nil {