refactor: update organization context in API routers

This commit is contained in:
Mauricio Siu
2025-02-20 01:42:35 -06:00
parent b73e4102dd
commit a9e12c2b18
7 changed files with 29 additions and 16 deletions

View File

@@ -25,7 +25,7 @@ export const gitlabRouter = createTRPCRouter({
.input(apiCreateGitlab)
.mutation(async ({ input, ctx }) => {
try {
return await createGitlab(input, ctx.user.ownerId);
return await createGitlab(input, ctx.session.activeOrganizationId);
} catch (error) {
throw new TRPCError({
code: "BAD_REQUEST",