Skip to content

Commit

Permalink
Merge pull request #182 from Scille/pymongo_io_validate
Browse files Browse the repository at this point in the history
Simplify "partial" in pymongo._io_validate_data_proxy
  • Loading branch information
lafrech committed Mar 18, 2019
2 parents 2ad7af9 + eed5bdd commit 0424772
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion umongo/frameworks/pymongo.py
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ def _run_validators(validators, field, value):
def _io_validate_data_proxy(schema, data_proxy, partial=None):
errors = {}
for name, field in schema.fields.items():
if partial and (partial is True or name not in partial):
if partial and name not in partial:
continue
data_name = field.attribute or name
value = data_proxy._data[data_name]
Expand Down

0 comments on commit 0424772

Please sign in to comment.