mirror of
https://github.com/zitadel/zitadel.git
synced 2024-12-14 20:08:02 +00:00
19 lines
488 B
Go
19 lines
488 B
Go
|
package auth
|
||
|
|
||
|
import (
|
||
|
"context"
|
||
|
|
||
|
"github.com/caos/zitadel/internal/api/authz"
|
||
|
auth_pb "github.com/caos/zitadel/pkg/grpc/auth"
|
||
|
)
|
||
|
|
||
|
func (s *Server) ListMyZitadelFeatures(ctx context.Context, _ *auth_pb.ListMyZitadelFeaturesRequest) (*auth_pb.ListMyZitadelFeaturesResponse, error) {
|
||
|
features, err := s.repo.GetOrgFeatures(ctx, authz.GetCtxData(ctx).OrgID)
|
||
|
if err != nil {
|
||
|
return nil, err
|
||
|
}
|
||
|
return &auth_pb.ListMyZitadelFeaturesResponse{
|
||
|
Result: features.FeatureList(),
|
||
|
}, nil
|
||
|
}
|