Skip to content

Commit

Permalink
Fix convert_decimal (#52)
Browse files Browse the repository at this point in the history
  • Loading branch information
tarsil committed Jul 15, 2024
1 parent 730c627 commit 84d2c17
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mongoz/core/db/documents/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ def convert_decimal(self, model_dump_dict: Dict[str, Any]) -> Dict[str, Any]:
self.convert_decimal(value)
elif isinstance(value, list):
for item in value:
if isinstance(item, (dict, list)):
if isinstance(item, dict):
self.convert_decimal(item)
elif isinstance(value, Decimal):
model_dump_dict[key] = Decimal128(str(value))
Expand Down

0 comments on commit 84d2c17

Please sign in to comment.