N°9875 - fix export from twig controller

This commit is contained in:
odain
2026-09-01 15:01:52 +02:00
parent f35af2b8b0
commit 8d1711bef5

View File

@@ -650,6 +650,7 @@ abstract class Controller extends AbstractController
foreach ($aFiles as $sFile) {
$oArchive->addFile($sFile, basename($sFile));
}
$sFilename = $oArchive->filename;
$oArchive->close();
if ($bUnlinkFiles) {
@@ -658,7 +659,7 @@ abstract class Controller extends AbstractController
}
}
$this->SendFileContent($oArchive->filename, $sDownloadArchiveName.'.zip', true, true);
$this->SendFileContent($sFilename, $sDownloadArchiveName.'.zip', true, true);
}
final protected function SendFileContent($sFilePath, $sDownloadArchiveName = null, $bFileTransfer = true, $bRemoveFile = false, $aHeaders = []): void