From fdeab55e9a6489b561ccb5fed65fd7ac14953da8 Mon Sep 17 00:00:00 2001 From: Paul Barrett Date: Tue, 19 Jan 2010 10:46:26 +0200 Subject: [PATCH] Fixed issue with bulk download lock not being deleted if the queue is empty --- lib/foldermanagement/compressionArchiveUtil.inc.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/foldermanagement/compressionArchiveUtil.inc.php b/lib/foldermanagement/compressionArchiveUtil.inc.php index 46361d6..1efb68b 100644 --- a/lib/foldermanagement/compressionArchiveUtil.inc.php +++ b/lib/foldermanagement/compressionArchiveUtil.inc.php @@ -648,8 +648,8 @@ class DownloadQueue $_SESSION['zipcompression'] = null; } - // check for any errors and if none found then create the entry for the zip file which will be used by the notification code - if (!PEAR::isError($res) && !PEAR::isError($result)/* && !PEAR::isError() // There was a third one here originally but I cannot remember what it was // */) { + if (count($queue) && !PEAR::isError($res) && !PEAR::isError($result)) { + // check for any errors and if none found then create the entry for the zip file which will be used by the notification code // create the db entry self::addItem($code, self::getFolderId($code), -1, 'zip'); // update the db entry with the appropriate status and message -- libgit2 0.21.4