Skip to content

Commit

Permalink
[BUGFIX] Avoid warning in LanguageService
Browse files Browse the repository at this point in the history
LanguageService->sL('LLL:') leads to a warning. Even
though this is of course a broken call, the code should
sanitize this case.

Resolves: #95636
Releases: master
Change-Id: Id96f4d1c7640cb042c5504a2dfbc2d04fbd9edc0
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/71634
Tested-by: core-ci <typo3@b13.com>
Tested-by: Jochen <rothjochen@gmail.com>
Tested-by: Stefan Bürk <stefan@buerk.tech>
Tested-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Christian Kuhn <lolli@schwarzbu.ch>
Reviewed-by: Jochen <rothjochen@gmail.com>
Reviewed-by: Stefan Bürk <stefan@buerk.tech>
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch>
  • Loading branch information
lolli42 committed Oct 13, 2021
1 parent b5c631e commit 6d279c8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion typo3/sysext/core/Classes/Localization/LanguageService.php
Expand Up @@ -182,7 +182,7 @@ public function sL($input)
}
$parts = explode(':', trim($restStr));
$parts[0] = $extPrfx . $parts[0];
$output = $this->getLLL($parts[1], $this->readLLfile($parts[0]));
$output = $this->getLLL($parts[1] ?? '', $this->readLLfile($parts[0]));
} else {
// Use a constant non-localizable label
$output = $input;
Expand Down

0 comments on commit 6d279c8

Please sign in to comment.