chore: make import paths consistent

pull/302/head
Yangshun Tay 2 years ago
parent 6d212b4561
commit e7fe80dc31

@ -1,10 +1,9 @@
import NextAuth, { type NextAuthOptions } from 'next-auth';
import GitHubProvider from 'next-auth/providers/github';
// Prisma adapter for NextAuth, optional and can be removed
import { PrismaAdapter } from '@next-auth/prisma-adapter';
import { env } from '../../../env/server.mjs';
import { prisma } from '../../../server/db/client';
import { env } from '~/env/server.mjs';
import { prisma } from '~/server/db/client';
export const authOptions: NextAuthOptions = {
// Configure one or more authentication providers

@ -2,7 +2,7 @@
import type { NextApiRequest, NextApiResponse } from 'next';
import { getServerAuthSession } from '../../server/common/get-server-auth-session';
import { getServerAuthSession } from '~/server/common/get-server-auth-session';
const restricted = async (req: NextApiRequest, res: NextApiResponse) => {
const session = await getServerAuthSession({ req, res });

@ -1,9 +1,8 @@
// Src/pages/api/trpc/[trpc].ts
import { createNextApiHandler } from '@trpc/server/adapters/next';
import { env } from '../../../env/server.mjs';
import { appRouter } from '../../../server/router';
import { createContext } from '../../../server/router/context';
import { env } from '~/env/server.mjs';
import { appRouter } from '~/server/router';
import { createContext } from '~/server/router/context';
// Export API handler
export default createNextApiHandler({

Loading…
Cancel
Save