Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions technic_chests/formspec.lua
Original file line number Diff line number Diff line change
Expand Up @@ -166,8 +166,10 @@ function technic.chests.get_receive_fields(nodename, data)
if meta:get_int("autosort") == 1 then
technic.chests.sort_inv(chest_inv, meta:get_int("sort_mode"))
end
technic.chests.update_formspec(pos, data)
return
if not fields.key_enter_field then
technic.chests.update_formspec(pos, data) -- Removes edit infotext field
return
end
end
if not technic.chests.change_allowed(pos, player, data.locked, data.protected) then
return
Expand Down Expand Up @@ -231,7 +233,7 @@ function technic.chests.get_receive_fields(nodename, data)
end
end
if data.digilines then
if fields.save_channel and fields.channel then
if fields.channel and (fields.save_channel or fields.key_enter_field == "channel") then
meta:set_string("channel", fields.channel)
end
for _,setting in pairs({"send_put", "send_take", "send_inject", "send_pull", "send_overflow"}) do
Expand All @@ -245,7 +247,7 @@ function technic.chests.get_receive_fields(nodename, data)
if fields.edit_infotext then
technic.chests.update_formspec(pos, data, true)
return
elseif fields.save_infotext and fields.infotext then
elseif fields.infotext and (fields.save_infotext or fields.key_enter_field == "infotext") then
meta:set_string("infotext", fields.infotext)
end
end
Expand Down
Loading