Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
forxer committed Aug 25, 2022
2 parents 1c68e6f + 505c514 commit 8d9373e
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
6 changes: 6 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
Changelog
=========

4.1.3 (2022-08-25)
------------------

- View shared $errors might be null


4.1.2 (2022-08-25)
------------------

Expand Down
10 changes: 6 additions & 4 deletions src/View/Components/NotifyComponent.php
Original file line number Diff line number Diff line change
Expand Up @@ -166,10 +166,12 @@ private function addErrorsSharedFromViews(): void

$errors = app('view')->shared('errors');

if ($errors->any()) {
foreach ($errors->all() as $error) {
$this->notify->nowError($error);
}
if (is_null($errors)) {
return;
}

foreach ($errors->all() as $error) {
$this->notify->nowError($error);
}

$errorsAlreadyAdded = true;
Expand Down

0 comments on commit 8d9373e

Please sign in to comment.