Skip to content
Snippets Groups Projects
Commit f19bbcc3 authored by Joshua Westerheide's avatar Joshua Westerheide Committed by Andreas Fernandez
Browse files

[BUGFIX] Fix extraction path of language packs in LanguagePackService

Due to the appended extension key an invalid directory structure was
created. The language pack ".zip" files already contain extension
directories.

Resolves: #84638
Releases: master
Related: #84131
Change-Id: I19d4fa418a5c09a88fb814fb0780e122655a24b0
Reviewed-on: https://review.typo3.org/56577


Reviewed-by: default avatarTim Schreiner <schreiner.tim@gmail.com>
Tested-by: default avatarTim Schreiner <schreiner.tim@gmail.com>
Reviewed-by: default avatarAnja Leichsenring <aleichsenring@ab-softlab.de>
Tested-by: default avatarAnja Leichsenring <aleichsenring@ab-softlab.de>
Tested-by: default avatarTYPO3com <no-reply@typo3.com>
Reviewed-by: default avatarAndreas Fernandez <a.fernandez@scripting-base.de>
Tested-by: default avatarAndreas Fernandez <a.fernandez@scripting-base.de>
parent d68a6204
Branches
Tags
No related merge requests found
......@@ -234,7 +234,8 @@ class LanguagePackService
$packageUrl = $key[0] . '/' . $key[1] . '/' . $key . '-l10n/' . $key . '-l10n-' . $iso . '.zip';
}
$absoluteExtractionPath = GeneralUtility::getFileAbsFileName('typo3conf/l10n/' . $iso . '/' . $key . '/');
$absoluteLanguagePath = GeneralUtility::getFileAbsFileName('typo3conf/l10n/' . $iso . '/');
$absoluteExtractionPath = $absoluteLanguagePath . $key . '/';
$absolutePathToZipFile = Environment::getVarPath() . '/transient/' . $key . '-l10n-' . $iso . '.zip';
$packExists = is_dir($absoluteExtractionPath);
......@@ -253,7 +254,7 @@ class LanguagePackService
GeneralUtility::mkdir_deep(Environment::getVarPath() . '/transient/');
$operationResult = GeneralUtility::writeFileToTypo3tempDir($absolutePathToZipFile, $languagePackContent) === null;
}
$this->unzipTranslationFile($absolutePathToZipFile, $absoluteExtractionPath);
$this->unzipTranslationFile($absolutePathToZipFile, $absoluteLanguagePath);
if ($operationResult) {
$operationResult = unlink($absolutePathToZipFile);
}
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment