Skip to content

Commit

Permalink
Merge pull request #186 from smartprocure/feature/relax-mongodb-version
Browse files Browse the repository at this point in the history
Use mongodb for ObjectId and relax its version
  • Loading branch information
stellarhoof authored Jan 25, 2024
2 parents 1ccd8a9 + 51427d8 commit 7f6517f
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 1,077 deletions.
5 changes: 3 additions & 2 deletions packages/provider-mongo/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,16 +36,17 @@
"packageManager": "[email protected]",
"dependencies": {
"@elastic/datemath": "^2.3.0",
"bson": "^6.2.0",
"debug": "^4.3.1",
"futil": "^1.76.0",
"lodash": "^4.17.4",
"moment": "^2.18.1",
"moment-timezone": "^0.5.28"
},
"peerDependencies": {
"mongodb": ">=4.0.0"
},
"devDependencies": {
"contexture": "^0.12.19",
"mongodb": "^4.17.0",
"mongodb-memory-server": "^9.1.1"
}
}
2 changes: 1 addition & 1 deletion packages/provider-mongo/src/example-types/facet.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import F from 'futil'
import _ from 'lodash/fp.js'
import { ObjectId } from 'bson'
import { ObjectId } from 'mongodb'

let projectStageFromLabelFields = (node) => ({
$project: {
Expand Down
2 changes: 1 addition & 1 deletion packages/provider-mongo/src/example-types/mongoId.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import _ from 'lodash/fp.js'
import { ObjectId } from 'bson'
import { ObjectId } from 'mongodb'

export default {
hasValue: (node) => node.values || node.value,
Expand Down
2 changes: 1 addition & 1 deletion packages/provider-mongo/src/example-types/mongoId.test.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import mongoId from './mongoId.js'
import { ObjectId } from 'bson'
import { ObjectId } from 'mongodb'

describe('mongoId', () => {
describe('mongoId.hasValue', () => {
Expand Down
2 changes: 1 addition & 1 deletion packages/provider-mongo/src/index.test.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import _ from 'lodash/fp.js'
import Contexture from 'contexture'
import { ObjectId } from 'bson'
import { ObjectId } from 'mongodb'
import {
mongoConnect,
mongoDisconnect,
Expand Down
Loading

0 comments on commit 7f6517f

Please sign in to comment.