At the moment, using mongoose with the mongodb adapter doesn't work.
insertOne() doesn't exist in mongoose.
mongoose uses create() instead.
line 58 :
replacing await this.Session.insertOne(value); // MUST be replaced for Mongoose
by await this.Session.create(value); // WORKS for Mongoose
does the trick for mongoose but won't probably work for mongodb adapter.
Maybe using the save()collection method which I believe works both in mongoose and mongodb could be the simplest solution to avoid creating a dedicated mongoose adapter ?
At the moment, using mongoose with the mongodb adapter doesn't work.
insertOne() doesn't exist in mongoose. mongoose uses create() instead.
line 58 : replacing
await this.Session.insertOne(value); // MUST be replaced for Mongoose
byawait this.Session.create(value); // WORKS for Mongoose
does the trick for mongoose but won't probably work for mongodb adapter.Maybe using the
save()
collection method which I believe works both in mongoose and mongodb could be the simplest solution to avoid creating a dedicated mongoose adapter ?