Neos.Neos/Classes/Routing/Aspects/RouteCacheAspect.php
public function addWorkspaceName(JoinPointInterface $joinPoint)
    {
        $tags = $joinPoint->getAdviceChain()->proceed($joinPoint);

        $values = $joinPoint->getMethodArgument('routeValues');

        if (isset($values['node']) && strpos($values['node'], '@') !== false) {
            // Build context explicitly without authorization checks because the security context isn't available yet
            // anyway and any Entity Privilege targeted on Workspace would fail at this point:
            $this->securityContext->withoutAuthorizationChecks(function () use ($values, &$tags) {
                $contextPathPieces = NodePaths::explodeContextPath($values['node']);
                $tags[] = $contextPathPieces['workspaceName'];
            });
        }
        return $tags;
    }
public function addWorkspaceName(JoinPointInterface $joinPoint)
    {
        $tags = $joinPoint->getAdviceChain()->proceed($joinPoint);

        $values = $joinPoint->getMethodArgument('routeValues');

        if (isset($values['node']) && strpos($values['node'], '@') !== false) {
            // Build context explicitly without authorization checks because the security context isn't available yet
            // anyway and any Entity Privilege targeted on Workspace would fail at this point:
            $this->securityContext->withoutAuthorizationChecks(function () use ($values, &$tags) {
                $contextPathPieces = NodePaths::explodeContextPath($values['node']);
                $tags[] = $contextPathPieces['workspaceName'];
            });
        }
        return $tags;
    }
public function addWorkspaceName ( JoinPointInterface $ joinPoint ) { $ tags = $ joinPoint -> getAdviceChain ( ) -> proceed ( $ joinPoint ) ; $ values = $ joinPoint -> getMethodArgument ( 'routeValues' ) ; if ( isset ( $ values [ 'node' ] ) && strpos ( $ values [ 'node' ] , '@' ) !== false ) { // Build context explicitly without authorization checks because the security context isn't available yet // anyway and any Entity Privilege targeted on Workspace would fail at this point: $ this -> securityContext -> withoutAuthorizationChecks ( function ( ) use ( $ values , & $ tags ) { $ contextPathPieces = NodePaths :: explodeContextPath ( $ values [ 'node' ] ) ; $ tags [ ] = $ contextPathPieces [ 'workspaceName' ] ; } ) ; } return $ tags ; }
Add the current workspace name as a tag for the route cache entry

@Flow\Around("method(Neos\Flow\Mvc\Routing\RouterCachingService->generateRouteTags())")
@param JoinPointInterface $joinPoint The current join point
@return array
Add the current workspace name as a tag for the route cache entry