view util/xpcall.lua @ 13045:da0b3cb9a2ec

util.human.io: table: use term_width() to discover terminal width
author Matthew Wild <mwild1@gmail.com>
date Fri, 07 Apr 2023 12:35:39 +0100
parents d10957394a3c
children
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;
};