diff options
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/mod_pubsub/pubsub.lib.lua | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/plugins/mod_pubsub/pubsub.lib.lua b/plugins/mod_pubsub/pubsub.lib.lua index 82c44a16..ebeb6175 100644 --- a/plugins/mod_pubsub/pubsub.lib.lua +++ b/plugins/mod_pubsub/pubsub.lib.lua @@ -596,9 +596,10 @@ end 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 |