summaryrefslogtreecommitdiff
path: root/modules/comment/helpers/comment_rss.php
diff options
context:
space:
mode:
authorThomas E. Horner <github.com@t-horner.com>2011-07-08 09:33:51 +0200
committerThomas E. Horner <github.com@t-horner.com>2011-07-08 09:33:51 +0200
commitfc942aacda07346fa9af04853659eaeac1e766d3 (patch)
tree9ad6ea876c062835a0d53a60b65b74c6571f275c /modules/comment/helpers/comment_rss.php
parente8382b960a3c19bb28140833e348e6c9c9db8a8a (diff)
availability of rss is now configurable
Diffstat (limited to 'modules/comment/helpers/comment_rss.php')
-rw-r--r--modules/comment/helpers/comment_rss.php12
1 files changed, 10 insertions, 2 deletions
diff --git a/modules/comment/helpers/comment_rss.php b/modules/comment/helpers/comment_rss.php
index d04e74cf..dd6efd87 100644
--- a/modules/comment/helpers/comment_rss.php
+++ b/modules/comment/helpers/comment_rss.php
@@ -20,8 +20,16 @@
class comment_rss_Core {
static function available_feeds($item, $tag) {
- $feeds["comment/newest"] = t("All new comments");
- if ($item) {
+ $avail = module::get_var("comment", "rss_available");
+ if($avail == "none") {
+ return array();
+ }
+
+ if($avail == "both" || $avail == "newest") {
+ $feeds["comment/newest"] = t("All new comments");
+ }
+
+ if ($item && ($avail == "both" || $avail == "onitem")) {
$feeds["comment/item/$item->id"] =
t("Comments on %title", array("title" => html::purify($item->title)));
}