feat: edge ready

This commit is contained in:
Henry
2024-01-03 12:31:52 +00:00
parent 20ef0f5ca2
commit 0ba6528c12
8 changed files with 4002 additions and 43 deletions

View File

@@ -12,7 +12,7 @@ import { type NextRequest } from "next/server";
import superjson from "superjson";
import { ZodError } from "zod";
import { getServerAuthSession } from "~/server/auth";
import { auth } from "~/server/auth";
import { db } from "~/server/db";
/**
@@ -38,7 +38,7 @@ interface CreateContextOptions {
* @see https://create.t3.gg/en/usage/trpc#-serverapitrpcts
*/
export const createInnerTRPCContext = async (opts: CreateContextOptions) => {
const session = await getServerAuthSession();
const session = await auth();
return {
session,