Skip to content

Commit

Permalink
Merge pull request #681 from and-voila/srizvi/issue680
Browse files Browse the repository at this point in the history
fix: add use session back #680
  • Loading branch information
srizvi authored Jan 28, 2024
2 parents d6b6f84 + 958f528 commit 17f127c
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 12 deletions.
7 changes: 4 additions & 3 deletions apps/ai/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,13 @@
"clean": "git clean -xdf .next .turbo node_modules",
"dev": "prisma generate && pnpm with-env next dev --port 3001",
"format": "prettier --check . --ignore-path ../../.gitignore",
"generate": "pnpm with-env prisma generate",
"knip": "knip",
"lint": "dotenv -v SKIP_ENV_VALIDATION=1 next lint",
"start": "prisma generate && pnpm with-env next start",
"studio": "prisma studio --dotenv=../../../../.env",
"start": "pnpm with-env prisma generate && pnpm with-env next start",
"typecheck": "tsc --noEmit",
"with-env": "dotenv -e ../../.env --"
"with-env": "dotenv -e ../../.env --",
"with-env-production": "dotenv -e ../../.env.production --"
},
"prisma": {
"schema": "./src/prisma/schema.prisma"
Expand Down
18 changes: 10 additions & 8 deletions apps/ai/src/components/providers/providers.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import type { ReactNode } from 'react';

import { SessionProvider } from 'next-auth/react';
import { Provider as BalancerProvider } from 'react-wrap-balancer';

import { Toaster } from '@av/ui/toaster';
Expand All @@ -14,14 +15,15 @@ import { ModalProvider } from '#/components/publish/modal/provider';
export function Providers({ children }: { children: ReactNode }) {
return (
<ThemeProvider attribute="class" defaultTheme="dark" enableSystem>
<ModalProvider>
<TopLoader />
{children}
</ModalProvider>

<ConfettiProvider />
<Toaster />
<BalancerProvider />
<SessionProvider>
<ModalProvider>
<TopLoader />
{children}
</ModalProvider>
<ConfettiProvider />
<Toaster />
<BalancerProvider />
</SessionProvider>
</ThemeProvider>
);
}
1 change: 1 addition & 0 deletions apps/ai/src/prisma/schema.prisma
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
datasource db {
provider = "postgresql"
url = env("DATABASE_URL")
directUrl = env("POSTGRES_URL_NON_POOLING")
}

generator client {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"engines": {
"node": ">=20.10"
},
"packageManager": "pnpm@8.14.0",
"packageManager": "pnpm@8.15.0",
"scripts": {
"build": "turbo build",
"clean": "git clean -xdf node_modules",
Expand Down

0 comments on commit 17f127c

Please sign in to comment.