@pi-r/aws-v3 0.12.5 → 0.13.0

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/client/index.js +2 -2
  2. package/package.json +2 -2
package/client/index.js CHANGED
@@ -326,7 +326,7 @@ async function executeBatchQuery(credential, batch, sessionKey) {
326
326
  throw formatError(item, "Missing database table");
327
327
  }
328
328
  if (useCache) {
329
- queryString = TableName + '_' + Cloud.asString(key, true) + (id !== undefined ? '_' + Cloud.asString(id, true) : '');
329
+ queryString = Cloud.keyForResult(TableName, key, id);
330
330
  if (!update && (rows = this.getCacheResult(service, credential, queryString, cacheValue, ignoreCache))) {
331
331
  result[i] = rows;
332
332
  continue;
@@ -404,7 +404,7 @@ async function executeBatchQuery(credential, batch, sessionKey) {
404
404
  else {
405
405
  update = '';
406
406
  }
407
- if (useCache && !update && (rows = this.getCacheResult(service, credential, queryString = Statement + '_' + Cloud.asString(Parameters, true) + '_' + (Limit ? Limit.toString() : '0'), cacheValue, ignoreCache))) {
407
+ if (useCache && !update && (rows = this.getCacheResult(service, credential, queryString = Cloud.keyForResult(Statement, Parameters, Limit || 0), cacheValue, ignoreCache))) {
408
408
  result[i] = rows;
409
409
  continue;
410
410
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-r/aws-v3",
3
- "version": "0.12.5",
3
+ "version": "0.13.0",
4
4
  "description": "AWS cloud functions for E-mc.",
5
5
  "main": "client/index.js",
6
6
  "repository": {
@@ -19,7 +19,7 @@
19
19
  "@e-mc/cloud": "^0.14.6",
20
20
  "@e-mc/module": "^0.14.6",
21
21
  "@e-mc/types": "^0.14.6",
22
- "@pi-r/aws-lib": "^0.12.5",
22
+ "@pi-r/aws-lib": "^0.13.0",
23
23
  "@aws-sdk/client-dynamodb": "^3.1118.0",
24
24
  "@aws-sdk/client-s3": "^3.1118.0",
25
25
  "@aws-sdk/credential-providers": "*",