--- a/plugins/mod_pubsub/pubsub.lib.lua Tue Jul 10 00:22:05 2018 +0200
+++ b/plugins/mod_pubsub/pubsub.lib.lua Tue Jul 10 00:51:55 2018 +0200
@@ -596,9 +596,10 @@
local function archive_itemstore(archive, config, user, node)
module:log("debug", "Creation of itemstore for node %s with config %s", node, config);
local get_set = {};
+ local max_items = config["max_items"];
function get_set:items() -- luacheck: ignore 212/self
local data, err = archive:find(user, {
- limit = tonumber(config["max_items"]);
+ limit = tonumber(max_items);
reverse = true;
});
if not data then