aboutsummaryrefslogtreecommitdiffstats
path: root/plugins
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2021-10-12 17:55:53 +0200
committerKim Alvefur <zash@zash.se>2021-10-12 17:55:53 +0200
commit1cfaaf66fd9e1ece3062a5f72f8f3654cbea1618 (patch)
tree08bb788060953a37aa7d0cc066457626b5292cfc /plugins
parent14367c5ef7d8e98cba7dc19c59ed5bd736da40a3 (diff)
downloadprosody-1cfaaf66fd9e1ece3062a5f72f8f3654cbea1618.tar.gz
prosody-1cfaaf66fd9e1ece3062a5f72f8f3654cbea1618.zip
mod_mimicking: Correctly hook the *global* user-deleted event
Diffstat (limited to 'plugins')
-rw-r--r--plugins/mod_mimicking.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/plugins/mod_mimicking.lua b/plugins/mod_mimicking.lua
index b586a70c..ab7612cb 100644
--- a/plugins/mod_mimicking.lua
+++ b/plugins/mod_mimicking.lua
@@ -29,7 +29,8 @@ module:hook("user-registered", function(user)
end
end);
-module:hook("user-deleted", function(user)
+module:hook_global("user-deleted", function(user)
+ if user.host ~= module.host then return end
local skel = skeleton(user.username);
local ok, err = skeletons:set(skel, nil);
if not ok and err then