fix: marshal displayname RoleDTO (#40015)

This commit is contained in:
Eric Leijonmarck
2021-10-05 16:29:34 +02:00
committed by GitHub
parent 52220b2470
commit 5374eaca89
+1
View File
@@ -101,6 +101,7 @@ func (r RoleDTO) GetDisplayName() string {
func (r RoleDTO) MarshalJSON() ([]byte, error) {
type Alias RoleDTO
r.DisplayName = r.GetDisplayName()
return json.Marshal(&struct {
Alias
Global bool `json:"global" xorm:"-"`