From 585ea819579405bbfe772d2e7fa647f54d5a17e2 Mon Sep 17 00:00:00 2001 From: Tim Almdal Date: Tue, 24 Feb 2009 19:52:01 +0000 Subject: Fix for ticket #98. The problem was that item::delete was deleting the parent album --- core/models/item.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'core') diff --git a/core/models/item.php b/core/models/item.php index 8898e923..329f9c43 100644 --- a/core/models/item.php +++ b/core/models/item.php @@ -100,9 +100,9 @@ class Item_Model extends ORM_MPTT { // If there is no name, the path is invalid so don't try to delete if (!empty($this->name)) { if ($this->is_album()) { - dir::unlink(dirname($original_path)); - dir::unlink(dirname($original_resize_path)); - dir::unlink(dirname($original_thumb_path)); + dir::unlink($original_path); + dir::unlink($original_resize_path); + dir::unlink($original_thumb_path); } else { unlink($original_path); unlink($original_resize_path); -- cgit v1.2.3