fix: add preferred team middleware

This commit is contained in:
David Nguyen
2025-02-26 19:42:42 +11:00
parent 5b4db51051
commit 6474b4a524
11 changed files with 173 additions and 54 deletions

View File

@ -9,6 +9,7 @@ import { openApiDocument } from '@documenso/trpc/server/open-api';
import { filesRoute } from './api/files';
import { type AppContext, appContext } from './context';
import { appMiddleware } from './middleware';
import { openApiTrpcServerHandler } from './trpc/hono-trpc-open-api';
import { reactRouterTrpcServer } from './trpc/hono-trpc-remix';
@ -26,6 +27,11 @@ const app = new Hono<HonoEnv>();
app.use(contextStorage());
app.use(appContext);
/**
* RR7 app middleware.
*/
app.use('*', appMiddleware);
// Auth server.
app.route('/api/auth', auth);