Mercurial > prosody-modules
diff mod_mam/mod_mam.lua @ 2022:77b9c7e5fd63
mod_mam: Allow interval between archive cleanup to be changed
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Tue, 19 Jan 2016 17:47:05 +0100 |
parents | 5fb917b86838 |
children | 98b4794b72e4 |
line wrap: on
line diff
--- a/mod_mam/mod_mam.lua Tue Jan 19 14:34:12 2016 +0100 +++ b/mod_mam/mod_mam.lua Tue Jan 19 17:47:05 2016 +0100 @@ -272,7 +272,7 @@ end local cleanup_after = module:get_option_string("archive_expires_after", "1w"); -local cleanup_interval = module:get_option_number("archive_expire_interval", 4 * 60 * 60); +local cleanup_interval = module:get_option_number("archive_cleanup_interval", 4 * 60 * 60); if cleanup_after ~= "never" then local day = 86400; local multipliers = { d = day, w = day * 7, m = 31 * day, y = 365.2425 * day }; @@ -308,7 +308,7 @@ end user[cleanup] = nil; end - return 14400; + return cleanup_interval; end); end