fix: fix mongoose connection

This commit is contained in:
arashsheyda
2023-04-23 00:30:00 +03:00
parent 5de7715356
commit 01f2c149fa

View File

@ -2,9 +2,8 @@ import { logger } from '@nuxt/kit'
import mongoose from 'mongoose'
import type { NuxtDevtoolsServerContext, ServerFunctions } from '../types'
export function setupDatabaseRPC({ nuxt }: NuxtDevtoolsServerContext): any {
// TODO:
mongoose.connect('mongodb://127.0.0.1:27017/arcane')
export function setupDatabaseRPC({ nuxt, options }: NuxtDevtoolsServerContext): any {
mongoose.connect(options.uri, options.options)
return {
async createCollection(name: string) {