src/ControllerPlugins.php
public function getPlugin($name, array $options = [])
    {
        $plugin = $this->get($name);
        if (! empty($options) && is_callable([$plugin, 'setOptions'])) {
            $plugin->setOptions($options);
        }

        return $plugin;
    }
public function getPlugin($name, array $options = [])
    {
        $plugin = $this->get($name);
        if (! empty($options) && is_callable([$plugin, 'setOptions'])) {
            $plugin->setOptions($options);
        }

        return $plugin;
    }
public function getPlugin ( $ name , array $ options = [ ] ) { $ plugin = $ this -> get ( $ name ) ; if ( ! empty ( $ options ) && is_callable ( [ $ plugin , 'setOptions' ] ) ) { $ plugin -> setOptions ( $ options ) ; } return $ plugin ; }
Gets the plugin and sets its options.

@param string $name    The plugin name
@param array  $options Optional; the plugin options

@return mixed The requested plugin
Gets the plugin and sets its options .