Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
ModuleOutput.php
Go to the documentation of this file.
1 <?php
8 
13 
18 {
24  private $subject;
25 
31  private $moduleManager;
32 
39  public function __construct(
40  CollectorInterface $subject,
41  Manager $moduleManager
42  ) {
43  $this->subject = $subject;
44  $this->moduleManager = $moduleManager;
45  }
46 
56  public function getFiles(ThemeInterface $theme, $filePath)
57  {
58  $result = [];
59  foreach ($this->subject->getFiles($theme, $filePath) as $file) {
60  if ($this->moduleManager->isOutputEnabled($file->getModule())) {
61  $result[] = $file;
62  }
63  }
64  return $result;
65  }
66 }
__construct(CollectorInterface $subject, Manager $moduleManager)
$moduleManager
Definition: products.php:75