Mercurial > hg > isophonics-drupal-site
diff vendor/symfony/translation/Extractor/AbstractFileExtractor.php @ 17:129ea1e6d783
Update, including to Drupal core 8.6.10
author | Chris Cannam |
---|---|
date | Thu, 28 Feb 2019 13:21:36 +0000 |
parents | 1fec387a4317 |
children |
line wrap: on
line diff
--- a/vendor/symfony/translation/Extractor/AbstractFileExtractor.php Tue Jul 10 15:07:59 2018 +0100 +++ b/vendor/symfony/translation/Extractor/AbstractFileExtractor.php Thu Feb 28 13:21:36 2019 +0000 @@ -27,15 +27,15 @@ */ protected function extractFiles($resource) { - if (is_array($resource) || $resource instanceof \Traversable) { - $files = array(); + if (\is_array($resource) || $resource instanceof \Traversable) { + $files = []; foreach ($resource as $file) { if ($this->canBeExtracted($file)) { $files[] = $this->toSplFileInfo($file); } } } elseif (is_file($resource)) { - $files = $this->canBeExtracted($resource) ? array($this->toSplFileInfo($resource)) : array(); + $files = $this->canBeExtracted($resource) ? [$this->toSplFileInfo($resource)] : []; } else { $files = $this->extractFromDirectory($resource); }