Skip to content

Commit

Permalink
Update handlers.py
Browse files Browse the repository at this point in the history
  • Loading branch information
juntatalor authored Aug 21, 2017
1 parent 748073f commit 908253a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tcrudge/handlers.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ def write_error(self, status_code, **kwargs):
self.write(err_text)
self.finish()

async def validate(self, data, schema, **kwargs):
async def validate(self, data, schema, format_checker=None, **kwargs):
"""
Method to validate parameters.
Raises HTTPError(400) with error info for invalid data.
Expand Down Expand Up @@ -141,7 +141,7 @@ async def validate(self, data, schema, **kwargs):
]
)
)
v = validator_for(schema)(schema, **kwargs)
v = validator_for(schema)(schema, format_checker=format_checker)
errors = []
for error in v.iter_errors(_data):
# error is an instance of jsonschema.exceptions.ValidationError
Expand Down

0 comments on commit 908253a

Please sign in to comment.