Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -106,14 +106,13 @@ def ns_value(self) -> Optional[List[str]]:
return self.get("NS")

@property
def null_value(self) -> Optional[bool]:
def null_value(self) -> None:
"""An attribute of type Null.

Example:
>>> {"NULL": True}
"""
item = self.get("NULL")
return None if item is None else bool(item)
return None

@property
def s_value(self) -> Optional[str]:
Expand Down
1 change: 1 addition & 0 deletions tests/functional/test_data_classes.py
Original file line number Diff line number Diff line change
Expand Up @@ -544,6 +544,7 @@ def test_dynamo_attribute_value_null_value():
attribute_value = AttributeValue(example_attribute_value)

assert attribute_value.get_type == AttributeValueType.Null
assert attribute_value.null_value is None
assert attribute_value.null_value == attribute_value.get_value


Expand Down