src/Traits/RedirectTrait.php
public function redirectConfig($name = null, $config = null)
    {
        if ($name === null && $config === null) {
            return $this->getConfig('redirect');
        }

        $path = sprintf('redirect.%s', $name);
        if ($config === null) {
            return $this->getConfig($path);
        }

        return $this->setConfig($path, $config);
    }
public function redirectConfig($name = null, $config = null)
    {
        if ($name === null && $config === null) {
            return $this->getConfig('redirect');
        }

        $path = sprintf('redirect.%s', $name);
        if ($config === null) {
            return $this->getConfig($path);
        }

        return $this->setConfig($path, $config);
    }
public function redirectConfig ( $ name = null , $ config = null ) { if ( $ name === null && $ config === null ) { return $ this -> getConfig ( 'redirect' ) ; } $ path = sprintf ( 'redirect.%s' , $ name ) ; if ( $ config === null ) { return $ this -> getConfig ( $ path ) ; } return $ this -> setConfig ( $ path , $ config ) ; }
Change redirect configuration

If both `$name` and `$config` is empty all redirection
rules will be returned.

If `$name` is provided and `$config` is null, the named
redirection configuration is returned.

If both `$name` and `$config` is provided, the configuration
is changed for the named rule.

$config should contain the following keys:
- type : name of the reader
- key  : the key to read inside the reader
- url  : the URL to redirect to

@param null|string $name Name of the redirection rule
@param null|array $config Redirection configuration
@return mixed
Change redirect configuration