Context adapter work
This commit is contained in:
@@ -3,7 +3,6 @@ import { Effect, Layer } from "effect"
|
||||
import { rpcHTTPRoot } from "../config"
|
||||
import { ExpressApp } from "../http/ExpressApp"
|
||||
import { TRPCContextCreator } from "../trpc/TRPCContextCreator"
|
||||
import { contextCreatorExpressAdapter } from "../trpc/adapters"
|
||||
import { RPCRouter } from "./RPCRouter"
|
||||
|
||||
|
||||
@@ -14,7 +13,7 @@ export module RPCRoute {
|
||||
app.use(yield* rpcHTTPRoot,
|
||||
createExpressMiddleware({
|
||||
router: yield* RPCRouter,
|
||||
createContext: contextCreatorExpressAdapter(yield* TRPCContextCreator),
|
||||
createContext: (yield* TRPCContextCreator).createExpressContext,
|
||||
}),
|
||||
)
|
||||
}))
|
||||
|
||||
Reference in New Issue
Block a user