Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
odan authored May 17, 2020
1 parent 1081a3e commit 49ca08d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,11 +42,11 @@ if (empty($data['username'])) {
You can now test the `ValidationResult` and throw an exception if it contains errors.

```php
<?php

if ($validationResult->isFailed()) {
// Global error message
$validationResult->setMessage('Please check your input');

// Trigger error response (see validation middleware)

throw new ValidationException($validationResult);
}
```
Expand Down

0 comments on commit 49ca08d

Please sign in to comment.