diff options
author | Matthew Wild <mwild1@gmail.com> | 2018-08-18 15:10:41 +0100 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2018-08-18 15:10:41 +0100 |
commit | 84a825533fefa3df91d2f0d61870375862d4ea1e (patch) | |
tree | de56a4bf7b2c9da5d1c6c20c0975bf8259886a8f /plugins/mod_pubsub | |
parent | df1abfdd10b291f3d170b2be1a8ce6ffd3b2ccc0 (diff) | |
download | prosody-84a825533fefa3df91d2f0d61870375862d4ea1e.tar.gz prosody-84a825533fefa3df91d2f0d61870375862d4ea1e.zip |
Pubsub: Add tests for :get_last_item() and fix for non-persistent nodes
Diffstat (limited to 'plugins/mod_pubsub')
-rw-r--r-- | plugins/mod_pubsub/pubsub.lib.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/plugins/mod_pubsub/pubsub.lib.lua b/plugins/mod_pubsub/pubsub.lib.lua index af4876e8..d1231183 100644 --- a/plugins/mod_pubsub/pubsub.lib.lua +++ b/plugins/mod_pubsub/pubsub.lib.lua @@ -872,8 +872,8 @@ local function archive_itemstore(archive, config, user, node) truncate = size; }); end - function get_set:tail() - -- This should conveniently return the last item + function get_set:head() + -- This should conveniently return the most recent item local item = self:get(nil); if item then return item.attr.id, item; |