Skip to content

Commit

Permalink
Merge pull request #174 from laminas/2.22.x-merge-up-into-2.23.x_LbYy…
Browse files Browse the repository at this point in the history
…leHb

Merge release 2.22.1 into 2.23.x
  • Loading branch information
Ocramius authored Aug 17, 2022
2 parents ae32391 + dd4f49f commit 70954f0
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
6 changes: 6 additions & 0 deletions psalm-baseline.xml
Original file line number Diff line number Diff line change
Expand Up @@ -712,9 +712,15 @@
</RedundantConditionGivenDocblockType>
</file>
<file src="src/Helper/Layout.php">
<PossiblyNullReference occurrences="1">
<code>plugin</code>
</PossiblyNullReference>
<RedundantCastGivenDocblockType occurrences="1">
<code>(string) $template</code>
</RedundantCastGivenDocblockType>
<UndefinedInterfaceMethod occurrences="1">
<code>plugin</code>
</UndefinedInterfaceMethod>
</file>
<file src="src/Helper/Navigation.php">
<InvalidFunctionCall occurrences="1">
Expand Down
7 changes: 1 addition & 6 deletions src/Helper/Layout.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@

use Laminas\View\Exception;
use Laminas\View\Model\ModelInterface as Model;
use Laminas\View\Renderer\PhpRenderer;

use function assert;
use function sprintf;
Expand Down Expand Up @@ -99,12 +98,8 @@ public function setTemplate($template)
protected function getViewModelHelper()
{
if (! $this->viewModelHelper) {
/**
* @psalm-suppress DeprecatedMethod
*/
$renderer = $this->getView();
assert($renderer instanceof PhpRenderer);
$helper = $renderer->plugin('view_model');
$helper = $renderer->plugin('view_model');
assert($helper instanceof ViewModel);
$this->viewModelHelper = $helper;
}
Expand Down

0 comments on commit 70954f0

Please sign in to comment.