Zend\Mvc\Controller\Plugin\Forward::getListenersToDetach PHP Method

getListenersToDetach() public method

Each entry in the array contains three keys: id (identifier for event-emitting component), event (the hooked event) and class (the class of listener that should be detached).
public getListenersToDetach ( ) : array
return array
    public function getListenersToDetach()
    {
        // If a blacklist has not been explicitly set, return the default:
        if (null === $this->listenersToDetach) {
            // We need to detach the InjectViewModelListener to prevent templates
            // from getting attached to the ViewModel twice when a calling action
            // returns the output generated by a forwarded action.
            $this->listenersToDetach = [['id' => 'Zend\\Stdlib\\DispatchableInterface', 'event' => MvcEvent::EVENT_DISPATCH, 'class' => 'Zend\\Mvc\\View\\Http\\InjectViewModelListener']];
        }
        return $this->listenersToDetach;
    }