1
0
Fork 0

Add some more return types

pull/10561/head
Jordi Boggiano 2022-02-22 16:57:56 +01:00
parent 6da38f83a0
commit 225b4d7c27
No known key found for this signature in database
GPG Key ID: 7BBD42C429EC80BC
5 changed files with 6 additions and 6 deletions

View File

@ -77,7 +77,7 @@ class GenericRule extends Rule
*
* @return string
*/
public function __toString()
public function __toString(): string
{
$result = $this->isDisabled() ? 'disabled(' : '(';

View File

@ -96,7 +96,7 @@ class MultiConflictRule extends Rule
*
* @return string
*/
public function __toString()
public function __toString(): string
{
// TODO multi conflict?
$result = $this->isDisabled() ? 'disabled(multi(' : '(multi(';

View File

@ -108,7 +108,7 @@ class Rule2Literals extends Rule
*
* @return string
*/
public function __toString()
public function __toString(): string
{
$result = $this->isDisabled() ? 'disabled(' : '(';

View File

@ -150,7 +150,7 @@ class Link
/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->source.' '.$this->description.' '.$this->target.' ('.$this->constraint.')';
}

View File

@ -327,8 +327,8 @@ class PlatformRepository extends ArrayRepository
}
// ICU TZData version => 2019c
if (Preg::isMatch('/^ICU TZData version => (?<version>.*)$/im', $info, $zoneinfoMatches)) {
$this->addLibrary('icu-zoneinfo', Version::parseZoneinfoVersion($zoneinfoMatches['version']), 'zoneinfo ("Olson") database for icu');
if (Preg::isMatch('/^ICU TZData version => (?<version>.*)$/im', $info, $zoneinfoMatches) && null !== ($version = Version::parseZoneinfoVersion($zoneinfoMatches['version']))) {
$this->addLibrary('icu-zoneinfo', $version, 'zoneinfo ("Olson") database for icu');
}
// Add a separate version for the CLDR library version