From 60848480887594e61339000259e5322340518071 Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Tue, 8 Sep 2009 10:20:06 -0700 Subject: Improve comment. --- modules/gallery/helpers/MY_url.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'modules/gallery/helpers') diff --git a/modules/gallery/helpers/MY_url.php b/modules/gallery/helpers/MY_url.php index 129efb91..1ca9a58f 100644 --- a/modules/gallery/helpers/MY_url.php +++ b/modules/gallery/helpers/MY_url.php @@ -26,9 +26,11 @@ class url extends url_Core { $query = ""; } - $parts = explode("/", $uri, 3); // @todo if we're only doing this for Item_Model, why not just put this - // all into Item_Model::url()? It'd make url::site() faster. + // all into Item_Model::url()? It'd make url::site() faster. Downside is that + // anywhere we refer to an item by id, eg url::site("albums/123") would have + // to load the item and do $item->url(); + $parts = explode("/", $uri, 3); if ($parts[0] == "albums" || $parts[0] == "photos" || $parts[0] == "movies") { $uri = model_cache::get("item", $parts[1])->relative_url(); } -- cgit v1.2.3