diff options
author | Bharat Mediratta <bharat@menalto.com> | 2009-07-17 12:51:27 -0700 |
---|---|---|
committer | Bharat Mediratta <bharat@menalto.com> | 2009-07-17 12:51:27 -0700 |
commit | cd907c2b42f8b50ebe6d490aab42365e16deb258 (patch) | |
tree | b58350f7d7ffebeb91d5d9d2f273c0561625664b /modules/gallery/helpers/item.php | |
parent | 8a6556b30bc34d69284df6246f4010a8835f3bc2 (diff) |
Change model_cache::clear() API to clear everything. This prevents
old ORM relationships from hanging around, which was causing problems
when doing MPTT manipulations (resulting in incorrect permission
propagation-- very bad!)
Diffstat (limited to 'modules/gallery/helpers/item.php')
-rw-r--r-- | modules/gallery/helpers/item.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/gallery/helpers/item.php b/modules/gallery/helpers/item.php index f40b5c97..80c25862 100644 --- a/modules/gallery/helpers/item.php +++ b/modules/gallery/helpers/item.php @@ -53,7 +53,7 @@ class item_Core { access::required("view", $parent); access::required("edit", $parent); - model_cache::clear("item", $parent->album_cover_item_id); + model_cache::clear(); $parent->album_cover_item_id = $item->is_album() ? $item->album_cover_item_id : $item->id; $parent->thumb_dirty = 1; $parent->save(); @@ -69,7 +69,7 @@ class item_Core { access::required("edit", $album); @unlink($album->thumb_path()); - model_cache::clear("item", $album->album_cover_item_id) ; + model_cache::clear(); $album->album_cover_item_id = null; $album->thumb_width = 0; $album->thumb_height = 0; |