diff options
| author | Bharat Mediratta <bharat@menalto.com> | 2009-06-14 16:40:57 -0700 | 
|---|---|---|
| committer | Bharat Mediratta <bharat@menalto.com> | 2009-06-14 16:40:57 -0700 | 
| commit | 00fad54c0babfb0643c2ab9da98b4b74af84d466 (patch) | |
| tree | a9f863c0139c2c2e5b7e4356e780f7aca37423c7 /modules/tag/helpers | |
| parent | 47bc53eb5c328254d431caebf8acfd2636969bb4 (diff) | |
Refactor feed code to use stdClass everywhere.  Fix bugs in the
max-pages calculation code.  Move feed related data into the $feed
variable and only pass that to the view.
Diffstat (limited to 'modules/tag/helpers')
| -rw-r--r-- | modules/tag/helpers/tag_rss.php | 11 | 
1 files changed, 5 insertions, 6 deletions
diff --git a/modules/tag/helpers/tag_rss.php b/modules/tag/helpers/tag_rss.php index 3d6399ca..dbef3914 100644 --- a/modules/tag/helpers/tag_rss.php +++ b/modules/tag/helpers/tag_rss.php @@ -21,7 +21,6 @@  class tag_rss_Core {    static function available_feeds($item) {      return array(array("description" => t("Tag Album feed"), -                       "type" => "head",                         "uri" => "tags"));    } @@ -31,11 +30,11 @@ class tag_rss_Core {        return Kohana::show_404();      } -    $feed["children"] = $tag->items($limit, $offset, "photo"); -    $feed["max_pages"] = ceil($tag->count / $limit); -    $feed["title"] = $tag->name; -    $feed["link"] = url::abs_site("tags/{$tag->id}"); -    $feed["description"] = t("Photos related to %tag_name", array("tag_name" => $tag->name)); +    $feed->children = $tag->items($limit, $offset, "photo"); +    $feed->max_pages = ceil($tag->count / $limit); +    $feed->title = $tag->name; +    $feed->link = url::abs_site("tags/{$tag->id}"); +    $feed->description = t("Photos related to %tag_name", array("tag_name" => $tag->name));      return $feed;    }  | 
