mirror of
https://git.minetest.land/VoxeLibre/VoxeLibre.git
synced 2024-11-22 18:41:09 +01:00
Fix crash when click on invalid item in craftguide
This commit is contained in:
parent
a349e421c8
commit
307622b4d7
1 changed files with 3 additions and 0 deletions
|
@ -19,6 +19,9 @@ local get_recipes = function(query_item)
|
||||||
-- doesn't return repairing recipes)
|
-- doesn't return repairing recipes)
|
||||||
if minetest.get_modpath("mcl_core") then
|
if minetest.get_modpath("mcl_core") then
|
||||||
local def = minetest.registered_items[query_item]
|
local def = minetest.registered_items[query_item]
|
||||||
|
if not def then
|
||||||
|
return
|
||||||
|
end
|
||||||
if def.type == "tool" then
|
if def.type == "tool" then
|
||||||
if recipes == nil then
|
if recipes == nil then
|
||||||
recipes = {}
|
recipes = {}
|
||||||
|
|
Loading…
Reference in a new issue