From 63fd2332f0469174be6476eb7455519ebaf30249 Mon Sep 17 00:00:00 2001 From: Brion Vibber Date: Wed, 25 Aug 2010 11:59:39 -0700 Subject: Use Status_network's caching settings when loading Status_network_tag entries; cache entries are batched per site and will be cleared when tags are inserted/deleted using the main interface. (with fixes from tagcache branch) --- classes/Status_network.php | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) (limited to 'classes/Status_network.php') diff --git a/classes/Status_network.php b/classes/Status_network.php index 5680c1458..c4f37ce1c 100644 --- a/classes/Status_network.php +++ b/classes/Status_network.php @@ -308,15 +308,7 @@ class Status_network extends Safe_DataObject */ function getTags() { - $result = array(); - - $tags = new Status_network_tag(); - $tags->site_id = $this->site_id; - if ($tags->find()) { - while ($tags->fetch()) { - $result[] = $tags->tag; - } - } + $result = Status_network_tag::getTags($this->site_id); // XXX : for backwards compatibility if (empty($result)) { @@ -329,6 +321,7 @@ class Status_network extends Safe_DataObject /** * Save a given set of tags * @param array tags + * @fixme only add/remove differentials */ function setTags($tags) { -- cgit v1.2.3-54-g00ecf