Improve type-safety
This commit is contained in:
parent
2b8b5d5743
commit
8eda7d4c7f
@ -430,7 +430,11 @@ final class NodaTimeAutotranslater {
|
||||
$output = [];
|
||||
foreach (self::LANGS_TO_CE_FORMAT as $tLang => $ceFormat) {
|
||||
|
||||
if (!empty($timeInfoToCopy) and $suffixMode === 2) {
|
||||
if ($suffixMode === 2) {
|
||||
|
||||
if (empty($timeInfoToCopy)) {
|
||||
throw new Exception("No time information to copy existent");
|
||||
}
|
||||
$ceIndicatorsToRemove = explode("%s", self::LANGS_TO_CE_FORMAT[$tLang]);
|
||||
$year = self::getTranslations($timeInfoToCopy)[$tLang];
|
||||
foreach ($ceIndicatorsToRemove as $ceIndicatorToRemove) {
|
||||
|
Loading…
Reference in New Issue
Block a user