* Mail: Fix download attachments as zip

Caused redirect with error message "Class 'mail_bo' not found"
This commit is contained in:
nathangray 2020-07-20 15:42:05 -06:00
parent 22c67c6801
commit 2a166fa47c

View File

@ -3156,7 +3156,7 @@ $filter['before']= date("d-M-Y", $cutoffdate2);
// Add subject to path, so it gets used as the file name, replacing ':'
// as it seems to cause an error
$path = $temp_path . '/' . ($header['SUBJECT'] ? Vfs::encodePathComponent(mail_bo::clean_subject_for_filename(str_replace(':','-', $header['SUBJECT']))) : lang('mail')) .'/';
$path = $temp_path . '/' . ($header['SUBJECT'] ? Vfs::encodePathComponent(Api\Mail::clean_subject_for_filename(str_replace(':','-', $header['SUBJECT']))) : lang('mail')) .'/';
if(!Vfs::mkdir($path, 0700, true))
{
echo "Unable to open temp directory $path";