Software /
code /
prosody-modules
Changeset
2401:7a1625a84624
mod_pubsub_feeds: Ask for leases that expire after one day (Years after testing this module, I was still subscribed to a GNU Social instance)
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Mon, 28 Nov 2016 08:48:23 +0100 |
parents | 2400:bd3a1df128a4 |
children | 2402:2040330586e4 |
files | mod_pubsub_feeds/mod_pubsub_feeds.lua |
diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/mod_pubsub_feeds/mod_pubsub_feeds.lua Sat Nov 26 00:34:05 2016 +0100 +++ b/mod_pubsub_feeds/mod_pubsub_feeds.lua Mon Nov 28 08:48:23 2016 +0100 @@ -47,6 +47,7 @@ local feed_list = module:shared("feed_list"); local refresh_interval; +local lease_length = tostring(math.floor(module:get_option_number("feed_lease_length", 86400))); function module.load() local config = module:get_option("feeds", { }); @@ -185,7 +186,7 @@ ["hub.topic"] = feed.url; ["hub.verify"] = "async"; -- COMPAT this is REQUIRED in the 0.3 draft but removed in 0.4 ["hub.secret"] = feed.secret; - --["hub.lease_seconds"] = ""; + ["hub.lease_seconds"] = lease_length; }; --module:log("debug", "subscription request, body: %s", body);