Skip to content

Commit

Permalink
fix: build
Browse files Browse the repository at this point in the history
  • Loading branch information
dsaltares committed Jul 30, 2024
1 parent 76d6cb2 commit 77d67f6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion app/src/server/createContext.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import type { inferAsyncReturnType } from '@trpc/server';
import type { CreateNextContextOptions } from '@trpc/server/adapters/next';
import type { Session } from 'next-auth';
import { getServerSession } from 'next-auth';
import authOptions from './auth/authOptions';

const createContext = async ({ req, res }: CreateNextContextOptions) => ({
session: await getServerSession(req, res, authOptions),
session: (await getServerSession(req, res, authOptions)) as Session | null,
});

export default createContext;
Expand Down

0 comments on commit 77d67f6

Please sign in to comment.