From b597ba4fadf2b6a9d455047bf8ba592da37ff2b7 Mon Sep 17 00:00:00 2001 From: Vitaliy Olkhin Date: Mon, 9 Sep 2024 11:52:25 +0500 Subject: [PATCH] caused the server to crash --- item_transport.lua | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/item_transport.lua b/item_transport.lua index ddf2a08..b8ac4b9 100644 --- a/item_transport.lua +++ b/item_transport.lua @@ -71,7 +71,9 @@ minetest.register_globalstep(function(dtime) for _, entity in pairs(luaentity.entities) do if entity.name == "pipeworks:tubed_item" then local h = minetest.hash_node_position(vector.round(entity._pos)) - tube_item_count[h] = (tube_item_count[h] or 0) + 1 + if type(tube_item_count[h]) ~= 'nil' then + tube_item_count[h] = (tube_item_count[h] or 0) + 1 + end end end end)