From cc2bd612ecf3d4a75eb5cd1875028348930bc554 Mon Sep 17 00:00:00 2001 From: Edsel Date: Thu, 28 Feb 2019 18:03:49 +0530 Subject: [PATCH] dev/core#769 - Fix for ZipArchive->open() PHP bug --- CRM/Financial/BAO/ExportFormat.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CRM/Financial/BAO/ExportFormat.php b/CRM/Financial/BAO/ExportFormat.php index ae05788a40..774fddcef3 100644 --- a/CRM/Financial/BAO/ExportFormat.php +++ b/CRM/Financial/BAO/ExportFormat.php @@ -251,7 +251,7 @@ abstract class CRM_Financial_BAO_ExportFormat { } if (count($validFiles)) { $zip = new ZipArchive(); - if ($zip->open($destination, $overwrite ? ZIPARCHIVE::OVERWRITE : ZIPARCHIVE::CREATE) !== TRUE) { + if ($zip->open($destination, $overwrite ? ZIPARCHIVE::CREATE | ZIPARCHIVE::OVERWRITE : ZIPARCHIVE::CREATE) !== TRUE) { return FALSE; } foreach ($validFiles as $file) { -- 2.25.1