Commit 9f1274ec authored by chenweijian's avatar chenweijian

隐藏的房间

parent 2f46ebf5
......@@ -66,7 +66,7 @@ func IsHiddenGroup(db *gorm.DB, groupId string) (bool, error) {
func IsHiddenGroupBy(model *domain.Model, imGroupId string) bool {
info := new(GroupSetting)
if err := model.DB().Model(GroupSetting{}).Where("im_group_id = ? and is_hidden = 1", imGroupId).First(&info).Error; err != nil {
if err := model.DB().Model(GroupSetting{}).Where("group_id = ? and is_hidden = 1", imGroupId).First(&info).Error; err != nil {
if err == gorm.ErrRecordNotFound {
return false
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment