check if message is found in mail.show_message

This commit is contained in:
BuckarooBanzay 2023-10-23 10:08:56 +02:00 committed by Athozus
parent f8f500ed76
commit 2111db2ff9

View File

@ -5,6 +5,11 @@ local FORMNAME = "mail:message"
function mail.show_message(name, id)
local message = mail.get_message(name, id)
if not message then
-- message not found or vanished
return
end
mail.selected_idxs.message[name] = id
local formspec = [[