From: paramat Date: Fri, 2 Feb 2018 18:11:17 +0000 (+0000) Subject: Doors: Avoid crash on nil player in 'can dig door' X-Git-Tag: 5.0.0~119 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=d5907d5f1e5dedb7ecc7a20e740e971403cf0f5a;p=oweals%2Fminetest_game.git Doors: Avoid crash on nil player in 'can dig door' --- diff --git a/mods/doors/init.lua b/mods/doors/init.lua index 51879678..2685357a 100644 --- a/mods/doors/init.lua +++ b/mods/doors/init.lua @@ -203,12 +203,7 @@ end local function can_dig_door(pos, digger) replace_old_owner_information(pos) - if default.can_interact_with_node(digger, pos) then - return true - else - minetest.record_protection_violation(pos, digger:get_player_name()) - return false - end + return default.can_interact_with_node(digger, pos) end function doors.register(name, def)