Sanitize team data
We don't want to expose sensitive data that might pose a security risk.
Этот коммит содержится в:
@@ -411,6 +411,7 @@ func findTeams(c *Context, w http.ResponseWriter, r *http.Request) {
|
||||
teams := result.Data.([]*model.Team)
|
||||
m := make(map[string]*model.Team)
|
||||
for _, v := range teams {
|
||||
v.Sanitize()
|
||||
m[v.Id] = v
|
||||
}
|
||||
|
||||
|
||||
@@ -219,3 +219,9 @@ func CleanTeamName(s string) string {
|
||||
|
||||
func (o *Team) PreExport() {
|
||||
}
|
||||
|
||||
func (o *Team) Sanitize() {
|
||||
o.Email = ""
|
||||
o.Type = ""
|
||||
o.AllowedDomains = ""
|
||||
}
|
||||
|
||||
Ссылка в новой задаче
Block a user