Skip to content

Commit 2436280

Browse files
committed
fix: Fixed dynamodb Get Unmarshaling bug
1 parent c720c6c commit 2436280

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

storage/dynamodb.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ func (s *DynamoDBAdapter) Get(dest any, filter map[string]any) error {
145145
if response.Item == nil {
146146
return ErrNotFound
147147
} else {
148-
err = attributevalue.UnmarshalMap(response.Item, &dest)
148+
err = attributevalue.UnmarshalMapWithOptions(response.Item, &dest, func(eo *attributevalue.DecoderOptions) { eo.TagKey = "json" })
149149
if err != nil {
150150
return fmt.Errorf("failed to unmarshal dynamodb Get result into dest, %v", err)
151151
}

0 commit comments

Comments
 (0)