From bc1c9a27f1fd2eaf3b41e0e6e5a11da0deab88b0 Mon Sep 17 00:00:00 2001 From: Heyder Date: Wed, 4 Mar 2020 23:17:03 -0300 Subject: [PATCH] fix use of _get_default result on _get_appended_list --- moto/dynamodb2/models.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/moto/dynamodb2/models.py b/moto/dynamodb2/models.py index 88f750775..747fa93a7 100644 --- a/moto/dynamodb2/models.py +++ b/moto/dynamodb2/models.py @@ -450,9 +450,7 @@ class Item(BaseModel): old_list_key = list_append_re.group(1) # old_key could be a function itself (if_not_exists) if old_list_key.startswith("if_not_exists"): - old_list = DynamoType( - expression_attribute_values[self._get_default(old_list_key)] - ) + old_list = DynamoType(self._get_default(old_list_key)) else: old_list = self.attrs[old_list_key.split(".")[0]] if "." in old_list_key: