Beispiel #1
0
 /**
  * @param ConfigFactory $configFactory
  */
 public function __construct(ConfigFactory $configFactory)
 {
     $this->configFactory = $configFactory;
     $this->config = $this->configFactory->create();
     $this->root = str_replace('\\', '/', $this->config->getMagentoBasePath());
     foreach ($this->config->getMagentoFilePermissions() as $code => $config) {
         if (!$this->isAbsolute($config['path'])) {
             $this->directories[$code]['path'] = $this->makeAbsolute($config['path']);
         }
     }
 }
Beispiel #2
0
 /**
  * Retrieve list of required directories
  *
  * @return array
  */
 public function getRequired()
 {
     if (!$this->required) {
         foreach ($this->config->getMagentoFilePermissions() as $code => $config) {
             if (isset($config['path'])) {
                 $this->required[$code] = $config['path'];
             }
         }
     }
     return array_values($this->required);
 }
Beispiel #3
0
 /**
  * @param string $path
  * @return array|false
  */
 protected function getFiles($path)
 {
     return Glob::glob($this->config->getMagentoBasePath() . $path);
 }