feat: createContext

This commit is contained in:
Justin Lin committed 2025-04-16 15:36:12 +08:00
1 parent 6326b84a60
commit 529869671c
3 files changed
+18 -8

No files matched your search

+2 -1
View File
@@ -19,6 +19,7 @@ import expiryRemovalScheduler from './containers/expiryChecker.js'
import setupTest from './utils/setupTest.js'
import logger from './utils/logger.js'
import { appRouter } from './routers/index.js'
import { createContext } from './trpc.js'
async function main() {
if (!config.secret) {
@@ -76,7 +77,7 @@ async function main() {
'/trpc',
trpcExpress.createExpressMiddleware({
router: appRouter,
// createContext,
createContext,
})
)
app.use(errorHandler)