Create a single filter
protected buildFilter ( string $name, array $config ) : MiniAsset\Filter\AssetFilterInterface | ||
$name | string | The name of the filter to build. |
$config | array | The configuration for the filter. |
Результат | MiniAsset\Filter\AssetFilterInterface |
/** * Create a single filter * * @param string $name The name of the filter to build. * @param array $config The configuration for the filter. * @return AssetCompress\Filter\AssetFilterInterface */ protected function buildFilter($name, $config) { $className = App::className($name, 'Filter'); if (!class_exists($className)) { $className = App::className('AssetCompress.' . $name, 'Filter'); } $className = $className ?: $name; return parent::buildFilter($className, $config); }