mirror of
https://github.com/openimsdk/open-im-server.git
synced 2025-04-06 04:15:46 +08:00
fix bug
This commit is contained in:
parent
af1d8fa834
commit
a01156feb6
@ -32,13 +32,14 @@ func InsertIntoGroup(groupInfo db.Group) error {
|
||||
groupInfo.GroupName = "Group Chat"
|
||||
}
|
||||
groupInfo.CreateTime = time.Now()
|
||||
if groupInfo.NotificationUpdateTime.Unix() < 0 {
|
||||
groupInfo.NotificationUpdateTime = utils.UnixSecondToTime(0)
|
||||
}
|
||||
err = dbConn.Table("groups").Create(groupInfo).Error
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if groupInfo.NotificationUpdateTime.Unix() < 0 {
|
||||
groupInfo.NotificationUpdateTime = time.Now()
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user