File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed
Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,9 @@ import { updateUserAfterCreationViaAuth } from "./graphql/users/logic";
1212import UserModel from "@models/User" ;
1313import { getBackendAddress } from "./app/actions" ;
1414
15- const client = new MongoClient ( process . env . DB_CONNECTION_STRING || "" ) ;
15+ const client = new MongoClient (
16+ process . env . DB_CONNECTION_STRING || "mongodb://localhost:27017" ,
17+ ) ;
1618const db = client . db ( ) ;
1719
1820const config : any = {
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ export default async function connectToDatabase(): Promise<MongoClient> {
1212 } ;
1313
1414 const dbConnection = await mongoose . connect (
15- process . env . DB_CONNECTION_STRING || "" ,
15+ process . env . DB_CONNECTION_STRING || "mongodb://localhost:27017 " ,
1616 options ,
1717 ) ;
1818 return dbConnection . connection . getClient ( ) as unknown as MongoClient ;
You can’t perform that action at this time.
0 commit comments