Allow to clear name with anvil

This commit is contained in:
Wuzzy 2018-02-02 05:40:22 +01:00
parent 86b7f537d5
commit 7c1e625451

View File

@ -31,7 +31,9 @@ local function update_anvil_slots(meta)
-- Just rename
if (not input1:is_empty() and input2:is_empty()) or (input1:is_empty() and not input2:is_empty()) then
if new_name ~= nil and new_name ~= "" then
if new_name == nil then
new_name = ""
end
local name_item
if input1:is_empty() then
name_item = input2
@ -54,9 +56,6 @@ local function update_anvil_slots(meta)
else
new_output = ""
end
else
new_output = ""
end
-- Set the new output slot
if new_output ~= nil then