From 1f9c5aeadbe7ba6d0d8507df5423099817192325 Mon Sep 17 00:00:00 2001 From: gearnode Date: Wed, 12 Mar 2025 14:02:18 +0100 Subject: [PATCH] Fix tenant not found when creating new organinzation Signed-off-by: gearnode --- pkg/server/api/console/v1/v1_resolver.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pkg/server/api/console/v1/v1_resolver.go b/pkg/server/api/console/v1/v1_resolver.go index b506e4dc3..67c2b063c 100644 --- a/pkg/server/api/console/v1/v1_resolver.go +++ b/pkg/server/api/console/v1/v1_resolver.go @@ -178,8 +178,7 @@ func (r *mutationResolver) DeletePeople(ctx context.Context, input types.DeleteP // CreateOrganization is the resolver for the createOrganization field. func (r *mutationResolver) CreateOrganization(ctx context.Context, input types.CreateOrganizationInput) (*types.CreateOrganizationPayload, error) { - // TODO: fix does not work now - svc := r.GetTenantServiceIfAuthorized(ctx, gid.NewTenantID()) + svc := r.proboSvc.WithTenant(gid.NewTenantID()) organization, err := svc.Organizations.Create(ctx, probo.CreateOrganizationRequest{ Name: input.Name,