Changeset

6967:d90a4d6a0e2c

mod_blocklist: Clear second level cache when user is deleted
author Kim Alvefur <zash@zash.se>
date Sat, 05 Dec 2015 22:46:50 +0100
parents 6963:e3be91ccca05
children 6968:828a10e0464b
files plugins/mod_blocklist.lua
diffstat 1 files changed, 1 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/mod_blocklist.lua	Thu Dec 03 16:12:44 2015 +0000
+++ b/plugins/mod_blocklist.lua	Sat Dec 05 22:46:50 2015 +0100
@@ -186,6 +186,7 @@
 -- Cache invalidation, solved!
 module:hook_global("user-deleted", function (event)
 	if event.host == module.host then
+		cache:set(event.username, nil);
 		cache[event.username] = nil;
 	end
 end);