changeset 763:bcf0c9fff512

mod_pubsub_feeds: Depend on pubsub instead of aborting if it's not loaded
author Kim Alvefur <zash@zash.se>
date Wed, 01 Aug 2012 16:08:54 +0200
parents 0a06cf46c263
children d11d91ee81ed
files mod_pubsub_feeds/mod_pubsub_feeds.lua
diffstat 1 files changed, 1 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/mod_pubsub_feeds/mod_pubsub_feeds.lua	Wed Aug 01 16:08:15 2012 +0200
+++ b/mod_pubsub_feeds/mod_pubsub_feeds.lua	Wed Aug 01 16:08:54 2012 +0200
@@ -16,11 +16,7 @@
 -- http://pubsubhubbub.googlecode.com/svn/trunk/pubsubhubbub-core-0.3.html
 
 local modules = hosts[module.host].modules;
-if not modules.pubsub or module:get_option("component_module") ~= "pubsub" then
-	module:log("warn", "Pubsub needs to be loaded on this host");
-	--module:log("debug", "component_module is %s", tostring(module:get_option("component_module")));
-	return
-end
+module:depends"pubsub";
 
 local date, time = os.date, os.time;
 local dt_parse, dt_datetime = require "util.datetime".parse, require "util.datetime".datetime;