@cocreate/mongodb 1.6.0 → 1.6.1
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.
- package/CHANGELOG.md +7 -0
- package/package.json +1 -1
- package/src/index.js +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,10 @@
|
|
|
1
|
+
## [1.6.1](https://github.com/CoCreate-app/CoCreate-mongodb/compare/v1.6.0...v1.6.1) (2023-08-17)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* typo db.array to db.collection ([1561ab9](https://github.com/CoCreate-app/CoCreate-mongodb/commit/1561ab9ad137dcb52575e804ced3659309701550))
|
|
7
|
+
|
|
1
8
|
# [1.6.0](https://github.com/CoCreate-app/CoCreate-mongodb/compare/v1.5.0...v1.6.0) (2023-08-17)
|
|
2
9
|
|
|
3
10
|
|
package/package.json
CHANGED
package/src/index.js
CHANGED
|
@@ -185,7 +185,7 @@ function array(action, data) {
|
|
|
185
185
|
[array, value] = array
|
|
186
186
|
}
|
|
187
187
|
|
|
188
|
-
const arrayObj = db.
|
|
188
|
+
const arrayObj = db.collection(array);
|
|
189
189
|
|
|
190
190
|
if (action == 'updateCollection') {
|
|
191
191
|
arrayObj.rename(value, function (error, result) {
|
|
@@ -294,7 +294,7 @@ function document(action, data) {
|
|
|
294
294
|
let arraysLength = arrays.length
|
|
295
295
|
for (let array of arrays) {
|
|
296
296
|
const db = client.db(database);
|
|
297
|
-
const arrayObj = db.
|
|
297
|
+
const arrayObj = db.collection(array);
|
|
298
298
|
|
|
299
299
|
let { query, sort } = getFilters(data);
|
|
300
300
|
if (data['organization_id']) {
|