lithium\net\http\Media::_initScopes()
Initialize static::$_scopes
with a lithium\core\Configuration
instance.
Source
protected static function _initScopes() {
static::$_scopes = Libraries::instance(null, 'configuration', [], static::$_classes);
static::$_scopes->initConfig = function($name, $config) {
$defaults = [
'absolute' => false,
'host' => 'localhost',
'scheme' => 'http://',
'base' => null,
'prefix' => '',
'path' => null,
'timestamp' => false,
'filter' => null,
'suffix' => null,
'check' => false
];
$config += $defaults;
$config['prefix'] = trim($config['prefix'], '/');
$config['base'] = $config['base'] ? trim($config['base'], '/') : $config['base'];
return $config;
};
}