Skip to content

Commit

Permalink
fix: typo db.array to db.collection
Browse files Browse the repository at this point in the history
  • Loading branch information
frankpagan committed Aug 17, 2023
1 parent 34cbb61 commit 1561ab9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ function array(action, data) {
[array, value] = array
}

const arrayObj = db.array(array);
const arrayObj = db.collection(array);

if (action == 'updateCollection') {
arrayObj.rename(value, function (error, result) {
Expand Down Expand Up @@ -294,7 +294,7 @@ function document(action, data) {
let arraysLength = arrays.length
for (let array of arrays) {
const db = client.db(database);
const arrayObj = db.array(array);
const arrayObj = db.collection(array);

let { query, sort } = getFilters(data);
if (data['organization_id']) {
Expand Down

0 comments on commit 1561ab9

Please sign in to comment.