mail/webmail/handler_mark_read.lua
2020-04-23 10:00:28 +02:00

10 lines
228 B
Lua

-- mark mail as read
function mail.handlers.mark_read(playername, index)
local messages = mail.getMessages(playername)
if messages[index] then
messages[index].unread = false
end
mail.setMessages(playername, messages)
end