@cocreate/crud-client
Advanced tools
Comparing version 1.33.13 to 1.33.14
{ | ||
"name": "@cocreate/crud-client", | ||
"version": "1.33.13", | ||
"version": "1.33.14", | ||
"description": "An useful CRUD api operate Create, read, update, delete with built in database. Can be used as a firebase alternative. Easily configured using HTML5 attributes and/or JavaScript API.", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
@@ -87,4 +87,5 @@ /******************************************************************************** | ||
let response | ||
if (isBrowser && indexeddb && data['storage'].includes('indexeddb')) { | ||
let response = await indexeddb.send(data) | ||
response = await indexeddb.send(data) | ||
@@ -98,11 +99,10 @@ let type = data.method.split('.')[0]; | ||
this.socket.send(response) | ||
} else { | ||
this.socket.send(response || data).then((response) => { | ||
resolve(response); | ||
}) | ||
} | ||
} else { | ||
this.socket.send(data).then((response) => { | ||
} | ||
if (!response || response.status !== 'resolve') { | ||
this.socket.send(response || data).then((response) => { | ||
resolve(response); | ||
}) | ||
} | ||
@@ -178,4 +178,3 @@ }) | ||
response = await indexeddb.send(response) | ||
if (!response[type].length || !response[type][0].organization_id) { | ||
if (!response[type].length || type === 'object' && response[type][0] && response[type][0]._id && Object.keys(response[type][0]).length === 1) { | ||
response.method = type + '.create' | ||
@@ -182,0 +181,0 @@ response[type] = data[type][i] |
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
200346
535