File

util/xpcall.lua @ 11038:efefdf71373b

mod_external_services: Prepare to allow more credential algorithms Not sure what algorithms might fit here. Separation makes some sense. This is also a preparation for having a callback. (See next commit)
author Kim Alvefur <zash@zash.se>
date Sat, 25 Jul 2020 12:09:19 +0200
parent 9561:cfc7b2f7251e
child 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"util.compat".xpcall;
end

return {
	xpcall = xpcall;
};