This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import { cookies } from 'next/headers';
|
||||
import '@/lib/env-config';
|
||||
|
||||
const TOKEN_COOKIE_NAME = 'habit-tracker-token';
|
||||
const TOKEN_COOKIE_OPTIONS = {
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import { drizzle } from 'drizzle-orm/node-postgres';
|
||||
import * as schema from './schema';
|
||||
import '@/lib/env-config';
|
||||
|
||||
const DATABASE_URL = process.env.POSTGRES_URL;
|
||||
if (!DATABASE_URL) {
|
||||
|
||||
4
lib/env-config.ts
Normal file
4
lib/env-config.ts
Normal file
@@ -0,0 +1,4 @@
|
||||
import { loadEnvConfig } from '@next/env';
|
||||
|
||||
const projectDir = process.cwd();
|
||||
loadEnvConfig(projectDir);
|
||||
Reference in New Issue
Block a user