Skip to content

Commit

Permalink
Update ErrorCollectorTrait.php
Browse files Browse the repository at this point in the history
  • Loading branch information
Steeven Andrian committed May 10, 2019
1 parent e0f53fd commit 024d871
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/Traits/Collectors/ErrorCollectorTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,10 @@ public function addErrors(array $errors)
*/
public function addError($code, $message)
{
$this->errors[ $code ] = language($message);
if(class_exists('\O2System\Kernel')) {
$this->errors[ $code ] = language($message);
} else {
$this->errors[ $code ] = $message;
}
}
}

0 comments on commit 024d871

Please sign in to comment.