Prevent potential crash caused by moss growth ABM
authoracmgit <undertakers_help@yahoo.com>
Sun, 2 Jun 2019 17:50:20 +0000 (19:50 +0200)
committerParamat <paramat@users.noreply.github.com>
Sun, 2 Jun 2019 17:50:20 +0000 (18:50 +0100)
mods/default/functions.lua

index e1e3e186652741345287b691f5c93cdb0850fdc1..183b5597bbbf703993ad67462df1396db8d20813 100644 (file)
@@ -560,7 +560,9 @@ minetest.register_abm({
        catch_up = false,
        action = function(pos, node)
                node.name = moss_correspondences[node.name]
-               minetest.set_node(pos, node)
+               if node.name then
+                       minetest.set_node(pos, node)
+               end
        end
 })