# HG changeset patch # User Kim Alvefur # Date 1507418912 -7200 # Node ID dd9fa511494ac984d076f2c53f38ecf41b365da5 # Parent ac5c90230c2cfed725fb3da2441a0384ee244b5c mod_pubsub: Add method to clear data from a simple_itemstore diff -r ac5c90230c2c -r dd9fa511494a plugins/mod_pubsub/pubsub.lib.lua --- a/plugins/mod_pubsub/pubsub.lib.lua Sun Oct 08 01:27:04 2017 +0200 +++ b/plugins/mod_pubsub/pubsub.lib.lua Sun Oct 08 01:28:32 2017 +0200 @@ -383,6 +383,9 @@ 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;