Skip to content
This repository has been archived by the owner on Aug 2, 2019. It is now read-only.

Commit

Permalink
Add explicit validation error if definition missing (ref #48)
Browse files Browse the repository at this point in the history
  • Loading branch information
leplatrem committed Feb 15, 2013
1 parent 1146b0b commit 709477c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions daybed/validators.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ def schema_validator(request):
schema = SchemaValidator(definition['definition'])
validator(request, schema)
else:
request.errors.add('path', 'modelname',
'Unknown model %s' % model_name)
request.errors.status = 404


Expand Down

0 comments on commit 709477c

Please sign in to comment.