diff options
author | Kim Alvefur <zash@zash.se> | 2020-10-09 17:34:04 +0200 |
---|---|---|
committer | Kim Alvefur <zash@zash.se> | 2020-10-09 17:34:04 +0200 |
commit | 9a137bf062a1141e22668634c16a627afc77dc50 (patch) | |
tree | d2284e96d401aeede58f396ef0f0370b1fb378ab /util | |
parent | c888b5fd8d5d9b865bd834141fe7832935eee385 (diff) | |
download | prosody-9a137bf062a1141e22668634c16a627afc77dc50.tar.gz prosody-9a137bf062a1141e22668634c16a627afc77dc50.zip |
util.startup: Retrieve less data for function string representation
debug.getinfo(f) collects more info than what is needed here.
Diffstat (limited to 'util')
-rw-r--r-- | util/startup.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/util/startup.lua b/util/startup.lua index f0b9b2c0..af126e8c 100644 --- a/util/startup.lua +++ b/util/startup.lua @@ -197,7 +197,7 @@ function startup.set_function_metatable() end end function mt.__tostring(f) - local info = debug.getinfo(f); + local info = debug.getinfo(f, "S"); return ("function(%s:%d)"):format(info.short_src:match("[^\\/]*$"), info.linedefined); end debug.setmetatable(function() end, mt); |