Skip to content

Commit 283f47f

Browse files
committedSep 12, 2017
Fix invalid node error message of //set and //mix
1 parent 35ad2f0 commit 283f47f

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed
 

‎worldedit_commands/init.lua

+2-8
Original file line numberDiff line numberDiff line change
@@ -398,10 +398,7 @@ minetest.register_chatcommand("/set", {
398398
privs = {worldedit=true},
399399
func = safe_region(function(name, param)
400400
local node = get_node(name, param)
401-
if not node then
402-
worldedit.player_notify(name, "Could not identify node \"" .. param .. "\"")
403-
return
404-
end
401+
if not node then return end
405402

406403
local count = worldedit.set(worldedit.pos1[name], worldedit.pos2[name], node)
407404
worldedit.player_notify(name, count .. " nodes set")
@@ -435,10 +432,7 @@ minetest.register_chatcommand("/mix", {
435432
local nodes = {}
436433
for nodename in param:gmatch("[^%s]+") do
437434
local node = get_node(name, nodename)
438-
if not node then
439-
worldedit.player_notify(name, "Could not identify node \"" .. name .. "\"")
440-
return
441-
end
435+
if not node then return end
442436
nodes[#nodes + 1] = node
443437
end
444438

0 commit comments

Comments
 (0)