# HG changeset patch # User Kim Alvefur # Date 1638632919 -3600 # Node ID c01532ae6a3bb76267e8fb5cf8b264aa7cb21a84 # Parent dc72581e04ff8dd217e05445f443d6ca139f8056 mod_http_file_share: Fix to take retention time into account It was lost in 6f4790b8deec when switching to mod_cron. diff -r dc72581e04ff -r c01532ae6a3b plugins/mod_http_file_share.lua --- a/plugins/mod_http_file_share.lua Sat Dec 04 15:03:26 2021 +0100 +++ b/plugins/mod_http_file_share.lua Sat Dec 04 16:48:39 2021 +0100 @@ -460,8 +460,9 @@ local prune_start = module:measure("prune", "times"); - module:daily("Remove expired files", function(_, boundary_time) + module:daily("Remove expired files", function(_, current_time) local prune_done = prune_start(); + local boundary_time = (current_time or os.time()) - expiry; local iter, total = assert(uploads:find(nil, {["end"] = boundary_time; total = true})); if total == 0 then