We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent be98eda commit 90f88f8Copy full SHA for 90f88f8
packages/db-mongodb/src/connect.ts
@@ -2,6 +2,7 @@ import type { ConnectOptions } from 'mongoose'
2
import type { Connect } from 'payload'
3
4
import mongoose from 'mongoose'
5
+import { defaultBeginTransaction } from 'payload'
6
7
import type { MongooseAdapter } from './index.js'
8
@@ -46,7 +47,7 @@ export const connect: Connect = async function connect(
46
47
48
if (!client.options.replicaSet) {
49
this.transactionOptions = false
- this.beginTransaction = undefined
50
+ this.beginTransaction = defaultBeginTransaction()
51
}
52
53
if (!this.mongoMemoryServer && !hotReload) {
0 commit comments