1
0
Fork 0
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:
Lars Mueller 2024-02-12 22:58:26 +01:00
parent eb52a149a0
commit a14320fc44
2 changed files with 8 additions and 4 deletions

View file

@ -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;
}