Skip to content
This repository has been archived by the owner on Mar 24, 2021. It is now read-only.

Commit

Permalink
Add detail to error message
Browse files Browse the repository at this point in the history
When receiving a large amount of data, it can be helpful for a client
to know which record caused the problem.
  • Loading branch information
jabley committed Apr 23, 2015
1 parent be73ddf commit 61add50
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion backdrop/core/validation.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ def validate_record_data(data):
'_end_at is not a valid datetime object')

if key == '_id' and not value_is_valid_id(value):
return invalid('_id is not a valid id')
return invalid('_id "{0}" is not a valid id'.format(value))

return valid()

Expand Down

0 comments on commit 61add50

Please sign in to comment.