Fix for ReturnValues.
This commit is contained in:
parent
bdd4ae824b
commit
4e9f4bfbbf
3 changed files with 10 additions and 3 deletions
|
|
@ -400,8 +400,12 @@ class DynamoHandler(BaseResponse):
|
|||
key = self.body['Key']
|
||||
update_expression = self.body.get('UpdateExpression')
|
||||
attribute_updates = self.body.get('AttributeUpdates')
|
||||
existing_item = dynamodb_backend2.get_item(name, key)
|
||||
item = dynamodb_backend2.update_item(name, key, update_expression, attribute_updates)
|
||||
|
||||
item_dict = item.to_json()
|
||||
item_dict['ConsumedCapacityUnits'] = 0.5
|
||||
if not existing_item:
|
||||
item_dict['Attributes'] = {}
|
||||
|
||||
return dynamo_json_dump(item_dict)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue