File

util/xpcall.lua @ 13339:c94989c557cd

mod_pubsub: Provide some node properties in summary template #1809 Gives some access to node details which are otherwise hard to determine if you only see the plain text summary, since it is shared based on the pubsub#type setting (or payload xmlns).
author Kim Alvefur <zash@zash.se>
date Wed, 22 Nov 2023 22:35:44 +0100
parent 12975:d10957394a3c
line wrap: on
line source

local xpcall = xpcall;

if select(2, xpcall(function (x) return x end, function () end,  "test")) ~= "test" then
	xpcall = require"prosody.util.compat".xpcall;
end

return {
	xpcall = xpcall;
};