@moicky/dynamodb 2.5.2 → 2.5.3

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.
@@ -100,8 +100,10 @@ class UpdateOperations {
100
100
  this.operation.args = {
101
101
  ...this.operation.args,
102
102
  ConditionExpression: expression,
103
- ExpressionAttributeNames: (0, lib_1.getAttributeNames)(values),
104
- ExpressionAttributeValues: Object.keys(values).reduce((acc, keyName) => {
103
+ ExpressionAttributeNames: (0, lib_1.getAttributeNames)(values, {
104
+ attributesToGet: (0, lib_1.getAttributesFromExpression)(expression),
105
+ }),
106
+ ExpressionAttributeValues: (0, lib_1.getAttributesFromExpression)(expression, ":").reduce((acc, keyName) => {
105
107
  acc[`:${keyName}`] = values[keyName];
106
108
  return acc;
107
109
  }, {}),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@moicky/dynamodb",
3
- "version": "2.5.2",
3
+ "version": "2.5.3",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "description": "Contains a collection of convenience functions for working with AWS DynamoDB",