summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--init.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/init.lua b/init.lua
index 1ee755c..f67f8bb 100644
--- a/init.lua
+++ b/init.lua
@@ -246,7 +246,7 @@ minetest.register_abm({
local inv = meta:get_inventory()
-- is barrel empty?
- if inv:is_empty("src") then
+ if not inv or inv:is_empty("src") then
return
end