@toa.io/storages.mongodb 1.0.0-alpha.35 → 1.0.0-alpha.36

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +7 -7
  2. package/src/record.js +2 -3
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@toa.io/storages.mongodb",
3
- "version": "1.0.0-alpha.35",
3
+ "version": "1.0.0-alpha.36",
4
4
  "description": "Toa MongoDB Storage Connector",
5
5
  "author": "temich <tema.gurtovoy@gmail.com>",
6
6
  "homepage": "https://github.com/toa-io/toa#readme",
@@ -19,13 +19,13 @@
19
19
  "test": "echo \"Error: run tests from root\" && exit 1"
20
20
  },
21
21
  "dependencies": {
22
- "@toa.io/console": "1.0.0-alpha.35",
23
- "@toa.io/conveyor": "1.0.0-alpha.35",
24
- "@toa.io/core": "1.0.0-alpha.35",
25
- "@toa.io/generic": "1.0.0-alpha.35",
26
- "@toa.io/pointer": "1.0.0-alpha.35",
22
+ "@toa.io/console": "1.0.0-alpha.36",
23
+ "@toa.io/conveyor": "1.0.0-alpha.36",
24
+ "@toa.io/core": "1.0.0-alpha.36",
25
+ "@toa.io/generic": "1.0.0-alpha.36",
26
+ "@toa.io/pointer": "1.0.0-alpha.36",
27
27
  "mongodb": "6.3.0",
28
28
  "saslprep": "1.0.3"
29
29
  },
30
- "gitHead": "72963a7fdab122c0afe5d33928f4614d6c4f2455"
30
+ "gitHead": "565b8309bc46dfde7bbb49bd760c2dca0c89b0ff"
31
31
  }
package/src/record.js CHANGED
@@ -10,10 +10,9 @@ function from (record) {
10
10
  if (record === undefined || record === null)
11
11
  return null
12
12
 
13
- record.id = record._id
14
- delete record._id
13
+ const { _id, ...rest } = record
15
14
 
16
- return record
15
+ return { id: _id, ...rest }
17
16
  }
18
17
 
19
18
  exports.to = to