Skip to content

Commit

Permalink
Pacify linter
Browse files Browse the repository at this point in the history
  • Loading branch information
Bernhard Schmitt committed Jun 18, 2023
1 parent 8088a4e commit 5dcdb4b
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion Neos.Neos/Classes/Controller/Service/NodesController.php
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,9 @@ public function indexAction(
->contentRepositoryId;
$contentRepository = $this->contentRepositoryRegistry->get($contentRepositoryId);

$nodePath = NodePath::tryFromString($contextNode);
$nodePath = $contextNode
? NodePath::tryFromString($contextNode)
: null;
$nodeAddress = null;
if (!$nodePath) {
$nodeAddress = $contextNode
Expand Down Expand Up @@ -153,6 +155,7 @@ public function indexAction(
if (!is_null($nodeAddress)) {
$entryNode = $subgraph->findNodeById($nodeAddress->nodeAggregateId);
} else {
/** @var NodePath $nodePath */
$entryNode = $subgraph->findNodeByPath($nodePath, null);
}

Expand Down

0 comments on commit 5dcdb4b

Please sign in to comment.