Skip to content

Commit

Permalink
Merge pull request #4956 from neos/bugfix/remove-VisibilityConstraint…
Browse files Browse the repository at this point in the history
…s-isDisabledContentShown

BUGFIX: Remove invalid `isDisabledContentShown()` method
  • Loading branch information
bwaidelich authored Mar 19, 2024
2 parents c3a81af + cac807b commit 38ecbd9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,18 +28,9 @@ public static function getRestrictionClause(
string $tableNamePrefix,
string $prefix = ''
): string {
if ($visibilityConstraints->isDisabledContentShown()) {
return '';
}
// TODO evaluate $visibilityConstraints->tagConstraints {@see Neos\ContentGraph\DoctrineDbalAdapter\Domain\Repository\ContentSubgraph::addSubtreeTagConstraints}

return '
AND NOT EXISTS (
SELECT 1
FROM ' . $tableNamePrefix . '_restrictionhyperrelation rest
WHERE rest.contentstreamid = ' . $prefix . 'h.contentstreamid
AND rest.dimensionspacepointhash = ' . $prefix . 'h.dimensionspacepointhash
AND ' . $prefix . 'n.nodeaggregateid = ANY(rest.affectednodeaggregateids)
)';
return '';
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,6 @@ private function __construct(
) {
}

public function isDisabledContentShown(): bool
{
return $this->tagConstraints->contain(SubtreeTag::disabled());
}

public function getHash(): string
{
return md5(implode('|', $this->tagConstraints->toStringArray()));
Expand Down

0 comments on commit 38ecbd9

Please sign in to comment.