mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Improve deprecation error messages
This commit is contained in:
parent
eb52a149a0
commit
a14320fc44
2 changed files with 8 additions and 4 deletions
|
@ -189,7 +189,7 @@ void log_deprecated(lua_State *L, std::string message, int stack_depth, bool onc
|
|||
}
|
||||
|
||||
if (mode == DeprecatedHandlingMode::Error)
|
||||
script_error(L, LUA_ERRRUN, nullptr, nullptr);
|
||||
throw LuaError(message);
|
||||
else if (log)
|
||||
infostream << script_get_backtrace(L) << std::endl;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue