MM-25014 - Default Group Name to null, until AllowGroupReference is set (#14651)

* make Group.Name a pointer to allow null

* fix unit tests

* fix build error

* fix unit test

* ensure Name field not nil

Co-authored-by: mattermod <mattermod@users.noreply.github.com>
Этот коммит содержится в:
Scott Bishel
2020-05-26 19:21:29 -06:00
коммит произвёл GitHub
родитель 91f010b8b7
Коммит ebece6c23a
16 изменённых файлов: 204 добавлений и 208 удалений

Просмотреть файл

@@ -353,7 +353,11 @@ func newAuditGroup(g *Group) auditGroup {
var group auditGroup
if g != nil {
group.ID = g.Id
group.Name = g.Name
if g.Name == nil {
group.Name = ""
} else {
group.Name = *g.Name
}
group.DisplayName = g.DisplayName
group.Description = g.Description
}