Neos.Neos/Classes/Service/Controller/WorkspaceController.php
public function publishNodeAction(NodeInterface $node, $targetWorkspaceName = null)
    {
        $targetWorkspace = ($targetWorkspaceName !== null) ? $this->workspaceRepository->findOneByName($targetWorkspaceName) : null;
        $this->publishingService->publishNode($node, $targetWorkspace);

        $this->throwStatus(204, 'Node published', '');
    }
public function publishNodeAction(NodeInterface $node, $targetWorkspaceName = null)
    {
        $targetWorkspace = ($targetWorkspaceName !== null) ? $this->workspaceRepository->findOneByName($targetWorkspaceName) : null;
        $this->publishingService->publishNode($node, $targetWorkspace);

        $this->throwStatus(204, 'Node published', '');
    }
public function publishNodeAction ( NodeInterface $ node , $ targetWorkspaceName = null ) { $ targetWorkspace = ( $ targetWorkspaceName !== null ) ? $ this -> workspaceRepository -> findOneByName ( $ targetWorkspaceName ) : null ; $ this -> publishingService -> publishNode ( $ node , $ targetWorkspace ) ; $ this -> throwStatus ( 204 , 'Node published' , '' ) ; }
Publishes the given node to the specified targetWorkspace

@param NodeInterface $node
@param string $targetWorkspaceName
@return void
Publishes the given node to the specified targetWorkspace