Upgrade framework
This commit is contained in:
@@ -25,15 +25,12 @@ class ChainExtractor implements ExtractorInterface
|
||||
*
|
||||
* @var ExtractorInterface[]
|
||||
*/
|
||||
private $extractors = array();
|
||||
private array $extractors = [];
|
||||
|
||||
/**
|
||||
* Adds a loader to the translation extractor.
|
||||
*
|
||||
* @param string $format The format of the loader
|
||||
* @param ExtractorInterface $extractor The loader
|
||||
*/
|
||||
public function addExtractor($format, ExtractorInterface $extractor)
|
||||
public function addExtractor(string $format, ExtractorInterface $extractor)
|
||||
{
|
||||
$this->extractors[$format] = $extractor;
|
||||
}
|
||||
@@ -41,7 +38,7 @@ class ChainExtractor implements ExtractorInterface
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function setPrefix($prefix)
|
||||
public function setPrefix(string $prefix)
|
||||
{
|
||||
foreach ($this->extractors as $extractor) {
|
||||
$extractor->setPrefix($prefix);
|
||||
@@ -51,7 +48,7 @@ class ChainExtractor implements ExtractorInterface
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function extract($directory, MessageCatalogue $catalogue)
|
||||
public function extract(string|iterable $directory, MessageCatalogue $catalogue)
|
||||
{
|
||||
foreach ($this->extractors as $extractor) {
|
||||
$extractor->extract($directory, $catalogue);
|
||||
|
||||
Reference in New Issue
Block a user