Skip to content

Commit

Permalink
MDL-73305 mod_folder: Download Folder in a mlang formated folder
Browse files Browse the repository at this point in the history
  • Loading branch information
tasosb committed Jun 29, 2022
1 parent 1f6ab2b commit 9b64f0a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion mod/folder/download_folder.php
Expand Up @@ -52,7 +52,8 @@
// Close the session.
\core\session\manager::write_close();

$filename = shorten_filename(clean_filename($folder->name . "-" . date("Ymd")) . ".zip");
$foldername = format_string($folder->name, true, ["context" => $context]);
$filename = shorten_filename(clean_filename($foldername . "-" . date("Ymd")) . ".zip");
$zipwriter = \core_files\archive_writer::get_stream_writer($filename, \core_files\archive_writer::ZIP_WRITER);

foreach ($files as $file) {
Expand Down

0 comments on commit 9b64f0a

Please sign in to comment.