updated-packages

This commit is contained in:
RafficMohammed
2023-01-08 00:13:22 +05:30
parent 3ff7df7487
commit da241bacb6
12659 changed files with 563377 additions and 510538 deletions

View File

@@ -51,7 +51,7 @@ abstract class FileDumper implements DumperInterface
*/
public function setBackup($backup)
{
@trigger_error(sprintf('The "%s()" method is deprecated since Symfony 4.1.', __METHOD__), E_USER_DEPRECATED);
@trigger_error(sprintf('The "%s()" method is deprecated since Symfony 4.1.', __METHOD__), \E_USER_DEPRECATED);
if (false !== $backup) {
throw new \LogicException('The backup feature is no longer supported.');
@@ -61,9 +61,9 @@ abstract class FileDumper implements DumperInterface
/**
* {@inheritdoc}
*/
public function dump(MessageCatalogue $messages, $options = array())
public function dump(MessageCatalogue $messages, $options = [])
{
if (!array_key_exists('path', $options)) {
if (!\array_key_exists('path', $options)) {
throw new InvalidArgumentException('The file dumper needs a path option.');
}
@@ -84,7 +84,7 @@ abstract class FileDumper implements DumperInterface
$intlPath = $options['path'].'/'.$this->getRelativePath($intlDomain, $messages->getLocale());
file_put_contents($intlPath, $this->formatCatalogue($messages, $intlDomain, $options));
$messages->replace(array(), $intlDomain);
$messages->replace([], $intlDomain);
try {
if ($messages->all($domain)) {
@@ -103,13 +103,11 @@ abstract class FileDumper implements DumperInterface
/**
* Transforms a domain of a message catalogue to its string representation.
*
* @param MessageCatalogue $messages
* @param string $domain
* @param array $options
* @param string $domain
*
* @return string representation
*/
abstract public function formatCatalogue(MessageCatalogue $messages, $domain, array $options = array());
abstract public function formatCatalogue(MessageCatalogue $messages, $domain, array $options = []);
/**
* Gets the file extension of the dumper.
@@ -123,10 +121,10 @@ abstract class FileDumper implements DumperInterface
*/
private function getRelativePath(string $domain, string $locale): string
{
return strtr($this->relativePathTemplate, array(
return strtr($this->relativePathTemplate, [
'%domain%' => $domain,
'%locale%' => $locale,
'%extension%' => $this->getExtension(),
));
]);
}
}