2021-03-19 17:46:26 +00:00
|
|
|
package management
|
|
|
|
|
2021-03-22 13:40:25 +00:00
|
|
|
import (
|
2022-04-26 23:01:45 +00:00
|
|
|
"github.com/zitadel/zitadel/internal/api/grpc/server/middleware"
|
2021-03-22 13:40:25 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
func (a *ListAppsResponse) Localizers() []middleware.Localizer {
|
|
|
|
if a == nil {
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
|
|
|
localizers := make([]middleware.Localizer, 0)
|
|
|
|
for _, a := range a.Result {
|
|
|
|
localizers = append(localizers, a.Localizers()...)
|
|
|
|
}
|
|
|
|
return localizers
|
|
|
|
}
|
|
|
|
|
|
|
|
func (a *GetAppByIDResponse) Localizers() []middleware.Localizer {
|
|
|
|
if a == nil || (a != nil && a.App == nil) {
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
|
|
|
return a.App.Localizers()
|
|
|
|
}
|
2021-03-19 17:46:26 +00:00
|
|
|
|
|
|
|
func (a *AddOIDCAppResponse) Localizers() []middleware.Localizer {
|
|
|
|
if a == nil {
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
|
|
|
if !a.NoneCompliant {
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
localizers := make([]middleware.Localizer, len(a.ComplianceProblems))
|
|
|
|
for i, problem := range a.ComplianceProblems {
|
|
|
|
localizers[i] = problem
|
|
|
|
}
|
|
|
|
return localizers
|
|
|
|
|
|
|
|
}
|