@cocreate/indexeddb 1.17.0 → 1.17.2
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 +20 -0
- package/docs/index.html +2 -2
- package/package.json +2 -2
- package/src/index.js +33 -35
- package/test/collections.js +4 -4
- package/test/databases.js +4 -4
- package/test/documents.js +5 -5
- package/test/indexes.js +4 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,23 @@
|
|
|
1
|
+
## [1.17.2](https://github.com/CoCreate-app/CoCreate-indexeddb/compare/v1.17.1...v1.17.2) (2023-11-12)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* bump dependencies for latest features ([df1aa3a](https://github.com/CoCreate-app/CoCreate-indexeddb/commit/df1aa3a5053e068f6f47a66d1d388314c202607c))
|
|
7
|
+
* isFIlter condition ([9fcbb15](https://github.com/CoCreate-app/CoCreate-indexeddb/commit/9fcbb158dad0c8fab4bc09c6701ad2d0c868ab03))
|
|
8
|
+
* limit handling ([43fe9c6](https://github.com/CoCreate-app/CoCreate-indexeddb/commit/43fe9c6d2029aa1486488c944c51c9ba342e4ebf))
|
|
9
|
+
* set $filter.index ([ab739a5](https://github.com/CoCreate-app/CoCreate-indexeddb/commit/ab739a5b41fe5a2ab10e799f328650e9f14a46d1))
|
|
10
|
+
|
|
11
|
+
## [1.17.1](https://github.com/CoCreate-app/CoCreate-indexeddb/compare/v1.17.0...v1.17.1) (2023-11-09)
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
### Bug Fixes
|
|
15
|
+
|
|
16
|
+
* $storage, $database, $array are arrays ([b6374f8](https://github.com/CoCreate-app/CoCreate-indexeddb/commit/b6374f84e4ff13751cc357bbba8d4c883380083f))
|
|
17
|
+
* meta name typo ([da33128](https://github.com/CoCreate-app/CoCreate-indexeddb/commit/da331289589ea151f78ce25942e18e133f6b87f1))
|
|
18
|
+
* update crud methods ([c74ed56](https://github.com/CoCreate-app/CoCreate-indexeddb/commit/c74ed5688bd9a25f4eb524064b799ad678bdcc57))
|
|
19
|
+
* updated date to ISO format with UTC timezone ([8bcc59a](https://github.com/CoCreate-app/CoCreate-indexeddb/commit/8bcc59a7d715937c6de139dcb12951a686aa1cff))
|
|
20
|
+
|
|
1
21
|
# [1.17.0](https://github.com/CoCreate-app/CoCreate-indexeddb/compare/v1.16.2...v1.17.0) (2023-11-03)
|
|
2
22
|
|
|
3
23
|
|
package/docs/index.html
CHANGED
|
@@ -11,10 +11,10 @@
|
|
|
11
11
|
sizes="32x32"
|
|
12
12
|
href="https://cocreate.app/images/favicon.ico" />
|
|
13
13
|
<meta
|
|
14
|
-
|
|
14
|
+
name="description"
|
|
15
15
|
content="A simple HTML5 and pure javascript component. Easy configuration using data-attributes and highly styleable." />
|
|
16
16
|
<meta
|
|
17
|
-
|
|
17
|
+
name="keywords"
|
|
18
18
|
content="helper classes, utility classes, css framework, css library, inline style classes" />
|
|
19
19
|
<meta name="robots" content="index,follow" />
|
|
20
20
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cocreate/indexeddb",
|
|
3
|
-
"version": "1.17.
|
|
3
|
+
"version": "1.17.2",
|
|
4
4
|
"description": "A simple indexeddb component in vanilla javascript. Easily configured using HTML5 data-attributes and/or JavaScript API.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"indexeddb",
|
|
@@ -58,6 +58,6 @@
|
|
|
58
58
|
"webpack-log": "^3.0.1"
|
|
59
59
|
},
|
|
60
60
|
"dependencies": {
|
|
61
|
-
"@cocreate/utils": "^1.
|
|
61
|
+
"@cocreate/utils": "^1.27.1"
|
|
62
62
|
}
|
|
63
63
|
}
|
package/src/index.js
CHANGED
|
@@ -22,9 +22,8 @@
|
|
|
22
22
|
* For details, visit <https://cocreate.app/licenses/> or contact us at sales@cocreate.app
|
|
23
23
|
*/
|
|
24
24
|
|
|
25
|
-
import { ObjectId, dotNotationToObject, searchData, sortData, queryData
|
|
25
|
+
import { ObjectId, dotNotationToObject, searchData, sortData, queryData } from '@cocreate/utils'
|
|
26
26
|
|
|
27
|
-
// let status = true;
|
|
28
27
|
let indexedDbFunction
|
|
29
28
|
|
|
30
29
|
function init() {
|
|
@@ -71,9 +70,7 @@ async function send(data) {
|
|
|
71
70
|
await processDatabase(data, newData, type)
|
|
72
71
|
} else {
|
|
73
72
|
if (!data['timeStamp'])
|
|
74
|
-
data['timeStamp'] = new Date()
|
|
75
|
-
else
|
|
76
|
-
data['timeStamp'] = new Date(data['timeStamp'])
|
|
73
|
+
data['timeStamp'] = new Date().toISOString();
|
|
77
74
|
|
|
78
75
|
let databases = data.database;
|
|
79
76
|
if (!databases && data.organization_id)
|
|
@@ -121,9 +118,9 @@ const processDatabase = (data, newData, type) => {
|
|
|
121
118
|
if (data.$filter && data.$filter.query) {
|
|
122
119
|
let isFilter = queryData(database, data.$filter.query)
|
|
123
120
|
if (isFilter)
|
|
124
|
-
newData.push({ $storage: 'indexeddb', ...database })
|
|
121
|
+
newData.push({ $storage: ['indexeddb'], ...database })
|
|
125
122
|
} else
|
|
126
|
-
newData.push({ $storage: 'indexeddb', ...database })
|
|
123
|
+
newData.push({ $storage: ['indexeddb'], ...database })
|
|
127
124
|
}
|
|
128
125
|
|
|
129
126
|
resolve()
|
|
@@ -274,9 +271,9 @@ async function processArray(data, newData, database, type) {
|
|
|
274
271
|
if (data.$filter && data.$filter.query) {
|
|
275
272
|
let isFilter = queryData({ name: objectStoreNames[i] }, data.$filter.query)
|
|
276
273
|
if (isFilter)
|
|
277
|
-
newData.push({ name: objectStoreNames, $storage: 'indexeddb', $database: database })
|
|
274
|
+
newData.push({ name: objectStoreNames, $storage: ['indexeddb'], $database: [database] })
|
|
278
275
|
} else
|
|
279
|
-
newData.push({ name: objectStoreNames[i], $storage: 'indexeddb', $database: database })
|
|
276
|
+
newData.push({ name: objectStoreNames[i], $storage: ['indexeddb'], $database: [database] })
|
|
280
277
|
}
|
|
281
278
|
} else {
|
|
282
279
|
db.close()
|
|
@@ -324,7 +321,7 @@ async function processArray(data, newData, database, type) {
|
|
|
324
321
|
}
|
|
325
322
|
|
|
326
323
|
if (!error)
|
|
327
|
-
newData.push({ name: array, $storage: 'indexeddb', $database: database
|
|
324
|
+
newData.push({ name: array, $storage: ['indexeddb'], $database: [database] })
|
|
328
325
|
else
|
|
329
326
|
errorHandler(data, error, database)
|
|
330
327
|
|
|
@@ -361,7 +358,7 @@ async function processIndex(data, newData, database, array, type) {
|
|
|
361
358
|
if (data.$filter && data.$filter.query)
|
|
362
359
|
if (!(queryData({ name }, data.$filter.query))) continue
|
|
363
360
|
|
|
364
|
-
newData.push({ name, $storage: 'indexeddb', $database: database, $array: array })
|
|
361
|
+
newData.push({ name, $storage: ['indexeddb'], $database: [database], $array: [array] })
|
|
365
362
|
}
|
|
366
363
|
db.close()
|
|
367
364
|
} else {
|
|
@@ -398,10 +395,10 @@ async function processIndex(data, newData, database, array, type) {
|
|
|
398
395
|
error = 'new index name already exist'
|
|
399
396
|
}
|
|
400
397
|
} else
|
|
401
|
-
error = 'index does not exist'
|
|
398
|
+
error = 'index does not exist';
|
|
402
399
|
|
|
403
400
|
if (!error)
|
|
404
|
-
newData.push({ name: index, $storage: 'indexeddb', $database: database, $array: array })
|
|
401
|
+
newData.push({ name: index, $storage: ['indexeddb'], $database: [database], $array: [array] })
|
|
405
402
|
else
|
|
406
403
|
errorHandler(data, error, database, array)
|
|
407
404
|
|
|
@@ -415,8 +412,13 @@ async function processObject(data, newData, database, array, type) {
|
|
|
415
412
|
let db = await processDatabase({ method: 'database.get', database })
|
|
416
413
|
|
|
417
414
|
try {
|
|
415
|
+
if (!data[type])
|
|
416
|
+
data[type] = []
|
|
417
|
+
if (data[type] && !Array.isArray(data[type]))
|
|
418
|
+
data[type] = [data[type]]
|
|
419
|
+
|
|
418
420
|
let isFilter
|
|
419
|
-
if (data.$filter
|
|
421
|
+
if (data.$filter)
|
|
420
422
|
isFilter = true
|
|
421
423
|
|
|
422
424
|
let arrayExist = db.objectStoreNames.contains(array)
|
|
@@ -432,10 +434,6 @@ async function processObject(data, newData, database, array, type) {
|
|
|
432
434
|
if (!array || !db)
|
|
433
435
|
throw new Error({ error: "This is an error message.", db, array });
|
|
434
436
|
|
|
435
|
-
if (!data[type])
|
|
436
|
-
data[type] = []
|
|
437
|
-
if (data[type] && !Array.isArray(data[type]))
|
|
438
|
-
data[type] = [data[type]]
|
|
439
437
|
|
|
440
438
|
if ((isFilter && !data[type].length) || data.isFilter)
|
|
441
439
|
data[type] = [{ isFilter: 'isEmptyObjectFilter' }];
|
|
@@ -452,6 +450,8 @@ async function processObject(data, newData, database, array, type) {
|
|
|
452
450
|
let upsert = data.upsert
|
|
453
451
|
|
|
454
452
|
for (let i = 0; i < data[type].length; i++) {
|
|
453
|
+
const reference = { $storage: ['indexeddb'], $database: [database], $array: [array] }
|
|
454
|
+
|
|
455
455
|
delete data[type][i].$storage
|
|
456
456
|
delete data[type][i].$database
|
|
457
457
|
delete data[type][i].$array
|
|
@@ -467,9 +467,7 @@ async function processObject(data, newData, database, array, type) {
|
|
|
467
467
|
// TODO: user_id || clientId shohould be retrieved from CoCreate
|
|
468
468
|
data[type][i]['created'] = { on: data.timeStamp, by: data.user_id || data.clientId }
|
|
469
469
|
data[type][i] = await add(objectStore, data[type][i])
|
|
470
|
-
data[type][i]
|
|
471
|
-
data[type][i].$database = database
|
|
472
|
-
data[type][i].$array = array
|
|
470
|
+
data[type][i] = { ...reference, ...data[type][i] }
|
|
473
471
|
|
|
474
472
|
} else {
|
|
475
473
|
if (data[type][i].$filter)
|
|
@@ -482,7 +480,8 @@ async function processObject(data, newData, database, array, type) {
|
|
|
482
480
|
if (data[type][i].$upsert)
|
|
483
481
|
upsert = data[type][i].$upsert
|
|
484
482
|
// TODO: user_id || clientId shohould be retrieved from CoCreate
|
|
485
|
-
data[type][i]
|
|
483
|
+
if (!data[type][i].modified)
|
|
484
|
+
data[type][i].modified = { on: data.timeStamp, by: data.user_id || data.clientId }
|
|
486
485
|
}
|
|
487
486
|
|
|
488
487
|
let index = 0, limit, range, direction
|
|
@@ -563,7 +562,7 @@ async function processObject(data, newData, database, array, type) {
|
|
|
563
562
|
continue
|
|
564
563
|
}
|
|
565
564
|
|
|
566
|
-
await openCursor(objectStore, range, direction, data, newData, isFilter, limit, database, array, upsert, type, i, globalOperators);
|
|
565
|
+
await openCursor(objectStore, range, direction, data, newData, isFilter, limit, database, array, upsert, type, i, globalOperators, reference);
|
|
567
566
|
|
|
568
567
|
if (index)
|
|
569
568
|
newData = newData.slice(index)
|
|
@@ -582,7 +581,7 @@ async function processObject(data, newData, database, array, type) {
|
|
|
582
581
|
}
|
|
583
582
|
}
|
|
584
583
|
|
|
585
|
-
function openCursor(objectStore, range, direction, data, newData, isFilter, limit, database, array, upsert, type, i, globalOperators) {
|
|
584
|
+
function openCursor(objectStore, range, direction, data, newData, isFilter, limit, database, array, upsert, type, i, globalOperators, reference) {
|
|
586
585
|
return new Promise(async (resolve, reject) => {
|
|
587
586
|
const request = objectStore.openCursor(range || null, direction);// next, prev
|
|
588
587
|
|
|
@@ -616,9 +615,7 @@ function openCursor(objectStore, range, direction, data, newData, isFilter, limi
|
|
|
616
615
|
if (update)
|
|
617
616
|
data[type][i] = await put(objectStore, update)
|
|
618
617
|
}
|
|
619
|
-
data[type][i]
|
|
620
|
-
data[type][i].$database = database
|
|
621
|
-
data[type][i].$array = array
|
|
618
|
+
data[type][i] = { ...reference, ...data[type][i] }
|
|
622
619
|
|
|
623
620
|
matchedLength++
|
|
624
621
|
|
|
@@ -647,19 +644,19 @@ function openCursor(objectStore, range, direction, data, newData, isFilter, limi
|
|
|
647
644
|
}
|
|
648
645
|
|
|
649
646
|
if (data[type][i]._id)
|
|
650
|
-
data[type][i] = {
|
|
647
|
+
data[type][i] = { ...reference, ...result }
|
|
651
648
|
else {
|
|
652
649
|
let object = data[type].find(obj => obj._id && obj._id === result._id)
|
|
653
650
|
if (object)
|
|
654
|
-
object = {
|
|
651
|
+
object = { ...reference, ...object, ...result }
|
|
655
652
|
else
|
|
656
|
-
newData.push({
|
|
653
|
+
newData.push({ ...reference, ...result })
|
|
657
654
|
}
|
|
658
655
|
|
|
659
656
|
matchedLength++
|
|
660
657
|
}
|
|
661
658
|
|
|
662
|
-
if (!limit || limit && (limit
|
|
659
|
+
if (!limit || limit && (limit > newData.length || limit > matchedLength)) {
|
|
663
660
|
cursor.continue();
|
|
664
661
|
} else if (cursor.close) {
|
|
665
662
|
cursor.close()
|
|
@@ -781,7 +778,6 @@ function createUpdate(update, data, globalOpertors) {
|
|
|
781
778
|
function dotNotationToObjectUpdate(data, object = {}) {
|
|
782
779
|
try {
|
|
783
780
|
for (const key of Object.keys(data)) {
|
|
784
|
-
let value = isValidDate(data[key])
|
|
785
781
|
let newObject = object
|
|
786
782
|
let oldObject = new Object(newObject)
|
|
787
783
|
let keys = key.replace(/\[(\d+)\]/g, '.$1').split('.');
|
|
@@ -862,9 +858,11 @@ function createData(data, newData, type) {
|
|
|
862
858
|
|
|
863
859
|
data[type].push(...newData)
|
|
864
860
|
|
|
865
|
-
if (data.$filter
|
|
866
|
-
|
|
867
|
-
|
|
861
|
+
if (data.$filter) {
|
|
862
|
+
if (data.$filter.sort)
|
|
863
|
+
data[type] = sortData(data[type], data.$filter.sort)
|
|
864
|
+
data.$filter.index += data[type].length
|
|
865
|
+
}
|
|
868
866
|
|
|
869
867
|
return data
|
|
870
868
|
}
|
package/test/collections.js
CHANGED
|
@@ -4,7 +4,7 @@ async function testArrays() {
|
|
|
4
4
|
return;
|
|
5
5
|
} else {
|
|
6
6
|
|
|
7
|
-
let createObject = await
|
|
7
|
+
let createObject = await Coindex.createeddb.process({
|
|
8
8
|
method: 'array.create',
|
|
9
9
|
database: ['testDatabase', 'testDatabase1', 'testDatabase2'],
|
|
10
10
|
array: ['testArray', 'testArray1', 'testArray2']
|
|
@@ -12,13 +12,13 @@ async function testArrays() {
|
|
|
12
12
|
})
|
|
13
13
|
console.log('createObject', createObject)
|
|
14
14
|
|
|
15
|
-
let readObject = await
|
|
15
|
+
let readObject = await Coindex.createeddb.process({
|
|
16
16
|
method: 'array.read',
|
|
17
17
|
database: ['testDatabase', 'testDatabase1', 'testDatabase2'],
|
|
18
18
|
})
|
|
19
19
|
console.log('readObject', readObject)
|
|
20
20
|
|
|
21
|
-
let updateObject = await
|
|
21
|
+
let updateObject = await Coindex.createeddb.process({
|
|
22
22
|
method: 'array.update',
|
|
23
23
|
database: ['testDatabase', 'testDatabase1', 'testDatabase2'],
|
|
24
24
|
array: { testArray: 'testArrayA' }
|
|
@@ -26,7 +26,7 @@ async function testArrays() {
|
|
|
26
26
|
console.log('updateObject', updateObject)
|
|
27
27
|
|
|
28
28
|
|
|
29
|
-
let deleteObject = await
|
|
29
|
+
let deleteObject = await Coindex.createeddb.process({
|
|
30
30
|
method: 'array.delete',
|
|
31
31
|
database: ['testDatabase', 'testDatabase1', 'testDatabase2'],
|
|
32
32
|
array: ['testArrayA', 'testArray1', 'testArray2']
|
package/test/databases.js
CHANGED
|
@@ -3,26 +3,26 @@ async function testDatabases() {
|
|
|
3
3
|
console.log("This browser doesn't support IndexedDB.");
|
|
4
4
|
return;
|
|
5
5
|
} else {
|
|
6
|
-
let createDatabase = await
|
|
6
|
+
let createDatabase = await Coindex.createeddb.process({
|
|
7
7
|
method: 'database.create',
|
|
8
8
|
database: 'testDB',
|
|
9
9
|
})
|
|
10
10
|
console.log('createDatabase', createDatabase)
|
|
11
11
|
|
|
12
|
-
let readDatabase = await
|
|
12
|
+
let readDatabase = await Coindex.createeddb.process({
|
|
13
13
|
method: 'database.read',
|
|
14
14
|
database: 'testDB',
|
|
15
15
|
})
|
|
16
16
|
console.log('readDatabase', readDatabase)
|
|
17
17
|
|
|
18
|
-
let updateDatabase = await
|
|
18
|
+
let updateDatabase = await Coindex.createeddb.process({
|
|
19
19
|
method: 'database.update',
|
|
20
20
|
database: { testDB: 'testDatabase1' }
|
|
21
21
|
})
|
|
22
22
|
console.log('updateDatabase', updateDatabase)
|
|
23
23
|
|
|
24
24
|
|
|
25
|
-
let deleteDatabase = await
|
|
25
|
+
let deleteDatabase = await Coindex.createeddb.process({
|
|
26
26
|
method: 'database.delete',
|
|
27
27
|
database: ['testDB', 'testDB1', 'testDB2'],
|
|
28
28
|
})
|
package/test/documents.js
CHANGED
|
@@ -4,7 +4,7 @@ async function testDocuments() {
|
|
|
4
4
|
return;
|
|
5
5
|
} else {
|
|
6
6
|
|
|
7
|
-
let createObject = await
|
|
7
|
+
let createObject = await Coindex.createeddb.process({
|
|
8
8
|
method: 'object.create',
|
|
9
9
|
database: ['testDatabase', 'testDatabase1', 'testDatabase2'],
|
|
10
10
|
array: ['testArray', 'testArray1', 'testArray2'],
|
|
@@ -18,7 +18,7 @@ async function testDocuments() {
|
|
|
18
18
|
console.log('createObject', createObject)
|
|
19
19
|
let _id = createObject.object[0]._id
|
|
20
20
|
|
|
21
|
-
let readObject = await
|
|
21
|
+
let readObject = await Coindex.createeddb.process({
|
|
22
22
|
method: 'object.read',
|
|
23
23
|
database: ['testDatabase', 'testDatabase1', 'testDatabase2'],
|
|
24
24
|
array: ['testArray', 'testArray1', 'testArray2'],
|
|
@@ -29,7 +29,7 @@ async function testDocuments() {
|
|
|
29
29
|
})
|
|
30
30
|
console.log('readObject', readObject)
|
|
31
31
|
|
|
32
|
-
let updateObject = await
|
|
32
|
+
let updateObject = await Coindex.createeddb.process({
|
|
33
33
|
method: 'object.update',
|
|
34
34
|
database: ['testDatabase', 'testDatabase1', 'testDatabase2'],
|
|
35
35
|
array: ['testArray', 'testArray1', 'testArray2'],
|
|
@@ -43,7 +43,7 @@ async function testDocuments() {
|
|
|
43
43
|
console.log('updateObject', updateObject)
|
|
44
44
|
|
|
45
45
|
|
|
46
|
-
let deleteObject = await
|
|
46
|
+
let deleteObject = await Coindex.createeddb.process({
|
|
47
47
|
method: 'object.delete',
|
|
48
48
|
database: ['testDatabase', 'testDatabase1', 'testDatabase2'],
|
|
49
49
|
array: ['testArray', 'testArray1', 'testArray2'],
|
|
@@ -60,7 +60,7 @@ async function testDocuments() {
|
|
|
60
60
|
})
|
|
61
61
|
console.log('deleteObject', deleteObject)
|
|
62
62
|
|
|
63
|
-
// let deleteDatabase = await
|
|
63
|
+
// let deleteDatabase = await Coindex.createeddb.deleteDatabase({
|
|
64
64
|
// database: ['testDatabase', 'testDatabase1', 'testDatabase2'],
|
|
65
65
|
// })
|
|
66
66
|
// console.log('deleteDatabase', deleteDatabase)
|
package/test/indexes.js
CHANGED
|
@@ -3,7 +3,7 @@ async function testIndexes() {
|
|
|
3
3
|
console.log("This browser doesn't support IndexedDB.");
|
|
4
4
|
return;
|
|
5
5
|
} else {
|
|
6
|
-
let createIndexes = await
|
|
6
|
+
let createIndexes = await Coindex.createeddb.createIndex({
|
|
7
7
|
database: ['testDB', 'testDB1', 'testDB2'],
|
|
8
8
|
array: ['testCollection', 'testCollection1', 'testCollection2'],
|
|
9
9
|
index: 'testIndexes'
|
|
@@ -11,20 +11,20 @@ async function testIndexes() {
|
|
|
11
11
|
})
|
|
12
12
|
console.log('createIndexes', createIndexes)
|
|
13
13
|
|
|
14
|
-
let readIndexes = await
|
|
14
|
+
let readIndexes = await Coindex.createeddb.readIndex({
|
|
15
15
|
database: ['testDB', 'testDB1', 'testDB2'],
|
|
16
16
|
array: ['testCollection', 'testCollection1', 'testCollection2']
|
|
17
17
|
})
|
|
18
18
|
console.log('readIndexes', readIndexes)
|
|
19
19
|
|
|
20
|
-
let updateIndexes = await
|
|
20
|
+
let updateIndexes = await Coindex.createeddb.updateIndex({
|
|
21
21
|
database: ['testDB', 'testDB1', 'testDB2'],
|
|
22
22
|
array: ['testCollection', 'testCollection1', 'testCollection2'],
|
|
23
23
|
index: { testIndexes: 'testIndexes1' }
|
|
24
24
|
})
|
|
25
25
|
console.log('updateIndexes', updateIndexes)
|
|
26
26
|
|
|
27
|
-
let deleteIndexes = await
|
|
27
|
+
let deleteIndexes = await Coindex.createeddb.deleteIndex({
|
|
28
28
|
database: ['testDB', 'testDB1', 'testDB2'],
|
|
29
29
|
array: ['testCollection', 'testCollection1', 'testCollection2'],
|
|
30
30
|
index: 'testIndexes1'
|