From 714a82d1e01996df451ebffb321181441ed065df Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Mon, 7 Sep 2009 21:49:19 -0700 Subject: Automagically generate pretty urls for movies, too. --- modules/gallery/helpers/MY_url.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'modules') diff --git a/modules/gallery/helpers/MY_url.php b/modules/gallery/helpers/MY_url.php index c25f2293..129efb91 100644 --- a/modules/gallery/helpers/MY_url.php +++ b/modules/gallery/helpers/MY_url.php @@ -27,7 +27,9 @@ class url extends url_Core { } $parts = explode("/", $uri, 3); - if ($parts[0] == "albums" || $parts[0] == "photos") { + // @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. + if ($parts[0] == "albums" || $parts[0] == "photos" || $parts[0] == "movies") { $uri = model_cache::get("item", $parts[1])->relative_url(); } return parent::site($uri . $query, $protocol); -- cgit v1.2.3