From d4d145a44302a1438df7416e3046457bc9582806 Mon Sep 17 00:00:00 2001 From: Tim Almdal Date: Fri, 12 Jun 2009 07:46:42 -0700 Subject: Change from an event driven model to a call driven model similiar to the task api. --- modules/comment/helpers/comment_event.php | 6 ------ modules/comment/helpers/comment_rss.php | 30 ++++++++++++++++++++++++++++++ 2 files changed, 30 insertions(+), 6 deletions(-) create mode 100644 modules/comment/helpers/comment_rss.php (limited to 'modules/comment/helpers') diff --git a/modules/comment/helpers/comment_event.php b/modules/comment/helpers/comment_event.php index fdf3a96f..a3beb27a 100644 --- a/modules/comment/helpers/comment_event.php +++ b/modules/comment/helpers/comment_event.php @@ -21,10 +21,4 @@ class comment_event_Core { static function item_before_delete($item) { Database::instance()->delete("comments", array("item_id" => $item->id)); } - - static function request_feed_links($event_data) { - $event_data->feeds[t("All new comments")] = "comments"; - $event_data->feeds[sprintf(t("Comments on %s"), $event_data->item->title)] = - "comments/{$event_data->item->id}"; - } } diff --git a/modules/comment/helpers/comment_rss.php b/modules/comment/helpers/comment_rss.php new file mode 100644 index 00000000..9ae28726 --- /dev/null +++ b/modules/comment/helpers/comment_rss.php @@ -0,0 +1,30 @@ + t("All new comments"), + "sidebar" => true, + "uri" => "comments"), + array("description" => sprintf(t("Comments on %s"), $item->title), + "sidebar" => true, + "uri" => "comments/{$item->id}")); + } +} \ No newline at end of file -- cgit v1.2.3