From a4f41e7bfc6c2d823eab1465258617cb033a452c Mon Sep 17 00:00:00 2001 From: tenplus1 Date: Thu, 30 Aug 2018 19:32:33 +0100 Subject: get_node_drops: Make empty drop return empty table (#7592) This stops get_node_drops from returning an empty string when using drop = "" and instead returns the supposed empty table instead {} --- builtin/game/item.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'builtin') diff --git a/builtin/game/item.lua b/builtin/game/item.lua index 591531db0..9b7569c77 100644 --- a/builtin/game/item.lua +++ b/builtin/game/item.lua @@ -197,7 +197,7 @@ function core.get_node_drops(node, toolname) return {nodename} elseif type(drop) == "string" then -- itemstring drop - return {drop} + return drop ~= "" and {drop} or {} elseif drop.items == nil then -- drop = {} to disable default drop return {} -- cgit v1.2.3