From 54cf37e917a44792a5bbbec913060b9ef9eb797b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Chmielowski?= Date: Wed, 8 Feb 2023 19:06:44 +0100 Subject: [PATCH] Invalidate vcard_xupdate cache on all nodes when vcard is updated --- src/mod_vcard_xupdate.erl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mod_vcard_xupdate.erl b/src/mod_vcard_xupdate.erl index bd04517b4..d169b78f4 100644 --- a/src/mod_vcard_xupdate.erl +++ b/src/mod_vcard_xupdate.erl @@ -107,7 +107,7 @@ user_send_packet(Acc) -> -spec vcard_set(iq()) -> iq(). vcard_set(#iq{from = #jid{luser = LUser, lserver = LServer}} = IQ) -> - ets_cache:delete(?VCARD_XUPDATE_CACHE, {LUser, LServer}), + ets_cache:delete(?VCARD_XUPDATE_CACHE, {LUser, LServer}, ejabberd_cluster:get_nodes()), ejabberd_sm:force_update_presence({LUser, LServer}), IQ; vcard_set(Acc) -> @@ -117,7 +117,7 @@ vcard_set(Acc) -> remove_user(User, Server) -> LUser = jid:nodeprep(User), LServer = jid:nameprep(Server), - ets_cache:delete(?VCARD_XUPDATE_CACHE, {LUser, LServer}). + ets_cache:delete(?VCARD_XUPDATE_CACHE, {LUser, LServer}, ejabberd_cluster:get_nodes()). %%==================================================================== %% Storage