public function hasRights(ResourceNode $resourceNode, array $userRoles): bool
    {
        $isAdmin = false;

        if ($workspace = $resourceNode->getWorkspace()) {
            $isAdmin = $this->security->isGranted('administrate', $workspace);
        }

        return 0 !== $this->rightsManager->getMaximumRights($userRoles, $resourceNode) || $isAdmin;
    }