Changeset

3464:13b394b0db82

mod_cache_c2s_caps: Fail to load if module:send_iq() is not available
author Matthew Wild <mwild1@gmail.com>
date Thu, 14 Feb 2019 17:06:16 +0000
parents 3463:2aaf93d2b219
children 3465:468082a9913c
files mod_cache_c2s_caps/mod_cache_c2s_caps.lua
diffstat 1 files changed, 2 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/mod_cache_c2s_caps/mod_cache_c2s_caps.lua	Wed Feb 13 15:52:58 2019 +0100
+++ b/mod_cache_c2s_caps/mod_cache_c2s_caps.lua	Thu Feb 14 17:06:16 2019 +0000
@@ -8,6 +8,8 @@
 -- Some clients (*ahem* poezio…) don’t include the @node in their result iq.
 local iq_node_map = {}
 
+assert(module.send_iq, "This module is not compatible with this version of Prosody.");
+
 local function iq_result_handler(event)
 	local origin, stanza = event.origin, event.stanza;