Skip to content

Commit a30e512

Browse files
committed
Merge branch '4.4' into 5.0
* 4.4: Add missing dots at the end of exception messages [DI][Form] Fixed test suite (TimeType changes & unresolved merge conflict) Fix bad merge Add missing dots at the end of exception messages
2 parents eba83bc + d30b50e commit a30e512

File tree

6 files changed

+6
-6
lines changed

6 files changed

+6
-6
lines changed

Data/Bundle/Compiler/GenrbCompiler.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ public function __construct(string $genrb = 'genrb', string $envVars = '')
3737
exec('which '.$genrb, $output, $status);
3838

3939
if (0 !== $status) {
40-
throw new RuntimeException(sprintf('The command "%s" is not installed', $genrb));
40+
throw new RuntimeException(sprintf('The command "%s" is not installed.', $genrb));
4141
}
4242

4343
$this->genrb = ($envVars ? $envVars.' ' : '').$genrb;

Data/Bundle/Reader/JsonBundleReader.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ public function read(string $path, string $locale)
4646
$data = json_decode(file_get_contents($fileName), true);
4747

4848
if (null === $data) {
49-
throw new RuntimeException(sprintf('The resource bundle "%s" contains invalid JSON: %s', $fileName, json_last_error_msg()));
49+
throw new RuntimeException(sprintf('The resource bundle "%s" contains invalid JSON: %s.', $fileName, json_last_error_msg()));
5050
}
5151

5252
return $data;

Data/Generator/LocaleDataGenerator.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ private function generateLocaleName(BundleEntryReaderInterface $reader, string $
165165
// i.e. in de_AT, "AT" is the region
166166
if ($region = \Locale::getRegion($locale)) {
167167
if (ctype_alpha($region) && !RegionDataGenerator::isValidCountryCode($region)) {
168-
throw new MissingResourceException('Skipping "'.$locale.'" due an invalid country.');
168+
throw new MissingResourceException(sprintf('Skipping "%s" due an invalid country.', $locale));
169169
}
170170

171171
$extras[] = str_replace(['(', ')'], ['[', ']'], $reader->readEntry($tempDir.'/region', $displayLocale, ['Countries', $region]));

DateFormatter/DateFormat/FullTransformer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ private function formatReplace(string $dateChars, \DateTime $dateTime): string
104104

105105
// handle unimplemented characters
106106
if (false !== strpos($this->notImplementedChars, $dateChars[0])) {
107-
throw new NotImplementedException(sprintf('Unimplemented date character "%s" in format "%s"', $dateChars[0], $this->pattern));
107+
throw new NotImplementedException(sprintf('Unimplemented date character "%s" in format "%s".', $dateChars[0], $this->pattern));
108108
}
109109

110110
return '';

Globals/IntlGlobals.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ public static function getErrorName(int $code): string
108108
public static function setError(int $code, string $message = '')
109109
{
110110
if (!isset(self::$errorCodes[$code])) {
111-
throw new \InvalidArgumentException(sprintf('No such error code: "%s"', $code));
111+
throw new \InvalidArgumentException(sprintf('No such error code: "%s".', $code));
112112
}
113113

114114
self::$errorMessage = $message ? sprintf('%s: %s', $message, self::$errorCodes[$code]) : self::$errorCodes[$code];

NumberFormatter/NumberFormatter.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -360,7 +360,7 @@ public function format($value, int $type = self::TYPE_DEFAULT)
360360
}
361361

362362
if (self::CURRENCY === $this->style) {
363-
throw new NotImplementedException(sprintf('%s() method does not support the formatting of currencies (instance with CURRENCY style). %s', __METHOD__, NotImplementedException::INTL_INSTALL_MESSAGE));
363+
throw new NotImplementedException(sprintf('%s() method does not support the formatting of currencies (instance with CURRENCY style). %s.', __METHOD__, NotImplementedException::INTL_INSTALL_MESSAGE));
364364
}
365365

366366
// Only the default type is supported.

0 commit comments

Comments
 (0)