Skip to content

Commit

Permalink
Change validation error from dict to array
Browse files Browse the repository at this point in the history
  • Loading branch information
cristophersfr committed Mar 28, 2019
1 parent ba28277 commit 3cac7c4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions bothub/api/v2/validation/validators.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ class DoesIntentExistValidator(object):
def __call__(self, value):
examples = RepositoryExample.objects.filter(intent=value)
if not examples.exists():
raise ValidationError({'intent': _(
raise ValidationError(_(
'Intent MUST match existing intents for training. '
)})
))


class DoesEntityAndLabelExistValidator(object):
Expand Down

0 comments on commit 3cac7c4

Please sign in to comment.