fix ts error

This commit is contained in:
wancat committed 2024-02-07 10:41:46 +08:00
1 parent 79a5dac7f1
commit 640d6b58c5
1 file changed
+2 -5
+2 -5
View File
@@ -6,10 +6,7 @@ export { default as Session } from './session.js'
export { default as Command } from './command.js'
export { default as UserProfile } from './userProfile.js'
export default async function connectDB(uri) {
const db = await mongoose.connect(uri, {
useNewUrlParser: true,
useUnifiedTopology: true,
})
export default async function connectDB(uri: string) {
const db = await mongoose.connect(uri)
return db.connection.getClient()
}