mirror of
https://github.com/luanti-org/minetest_game.git
synced 2025-05-20 22:33:16 -04:00
mtg_craftguide: fix nil error
Fixes: "ERROR[Main]: ServerError: AsyncErr: ServerThread::run Lua: Runtime error from /home/xanadu/.minetest/mods/mtg_craftguide/init.lua:412: attempt to index local 'info' (a nil value)" It seems that some 5.x clients cause a "[Server]: static int ModApiServer::l_get_player_information(lua_state*): peer was not found" issue and cause nil to be returned for the player information fields.
This commit is contained in:
parent
1ade8941b4
commit
42478293ea
1 changed files with 1 additions and 1 deletions
|
@ -410,7 +410,7 @@ minetest.register_on_joinplayer(function(player)
|
||||||
filter = "",
|
filter = "",
|
||||||
pagenum = 1,
|
pagenum = 1,
|
||||||
items = init_items,
|
items = init_items,
|
||||||
lang_code = info.lang_code
|
lang_code = info and info.lang_code or "en"
|
||||||
}
|
}
|
||||||
end)
|
end)
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue