diff options
author | Kim Alvefur <zash@zash.se> | 2017-10-08 01:28:32 +0200 |
---|---|---|
committer | Kim Alvefur <zash@zash.se> | 2017-10-08 01:28:32 +0200 |
commit | c900502c9c5ece766638f0fc7a9df05c878ed11c (patch) | |
tree | 0186324224643559c3974e7419fd3a2d0bda9428 /plugins | |
parent | f8505ab244e435680779369378080a65ede3718b (diff) | |
download | prosody-c900502c9c5ece766638f0fc7a9df05c878ed11c.tar.gz prosody-c900502c9c5ece766638f0fc7a9df05c878ed11c.zip |
mod_pubsub: Add method to clear data from a simple_itemstore
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/mod_pubsub/pubsub.lib.lua | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/plugins/mod_pubsub/pubsub.lib.lua b/plugins/mod_pubsub/pubsub.lib.lua index e33fe836..5e09dab3 100644 --- a/plugins/mod_pubsub/pubsub.lib.lua +++ b/plugins/mod_pubsub/pubsub.lib.lua @@ -383,6 +383,9 @@ local function simple_itemstore(archive, config, user, node, expose_publisher) end return data; end + function get_set:clear() + return archive:delete(user, { with = node }); + end return setmetatable(get_set, archive); end _M.simple_itemstore = simple_itemstore; |