function CssAssetController::getGroups

Same name in other branches
  1. 11.x core/modules/system/src/Controller/CssAssetController.php \Drupal\system\Controller\CssAssetController::getGroups()

Overrides AssetControllerBase::getGroups

File

core/modules/system/src/Controller/CssAssetController.php, line 47

Class

CssAssetController
Defines a controller to serve CSS aggregates.

Namespace

Drupal\system\Controller

Code

protected function getGroups(AttachedAssetsInterface $attached_assets, Request $request) : array {
    $language = $this->languageManager()
        ->getLanguage($request->get('language'));
    $assets = $this->assetResolver
        ->getCssAssets($attached_assets, FALSE, $language);
    return $this->grouper
        ->group($assets);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.