From 639b497e3604e3f8a452e4e8d5cf98c676e356dc Mon Sep 17 00:00:00 2001 From: Auke Kok Date: Sun, 25 Aug 2019 22:04:28 -0700 Subject: [PATCH] Explicitly log msgid's to better track issues. --- mods/telex/init.lua | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/mods/telex/init.lua b/mods/telex/init.lua index 9004c1c..27f3813 100644 --- a/mods/telex/init.lua +++ b/mods/telex/init.lua @@ -220,7 +220,7 @@ function telex.deliver(msgid, msg) pmeta:set_string("telex_mbox", telex.encode(mbox)) minetest.chat_send_player(msg.to, "You have a new message from <" .. msg.from .. ">, use a terminal to read your messages"); - minetest.log("action", "telex: delivered a message from <" .. msg.from .. "> to <" .. msg.to .. ">") + minetest.log("action", "telex: delivered " .. msgid .. " from <" .. msg.from .. "> to <" .. msg.to .. ">") else -- append to spool msg.age = 7 * 86400 -- 7 days max in spool @@ -228,8 +228,8 @@ function telex.deliver(msgid, msg) local spool = telex.decode(S:get_string("telex_spool")) table.insert(spool, msgid) S:set_string("telex_spool", telex.encode(spool)) - minetest.log("action", "telex: spooled a message from <" .. msg.from .. "> to <" .. msg.to .. ">") - announce.admins("spooled a message from <" .. msg.from .. "> to <" .. msg.to .. ">") + minetest.log("action", "telex: spooled " .. msgid .. " from <" .. msg.from .. "> to <" .. msg.to .. ">") + announce.admins("spooled " .. msgid .. " from <" .. msg.from .. "> to <" .. msg.to .. ">") end end @@ -238,8 +238,8 @@ function telex.retour(msgid) local msg = telex.get_msg(msgid) if msg.from == "MAILER-DEAMON" then -- discard, we tried hard enough! - minetest.log("action", "telex: discarded an expired spool message from <" .. msg.from .. "> to <" .. msg.to .. ">") - announce.admins("discarded an expired spool message from <" .. msg.from .. "> to <" .. msg.to .. ">") + minetest.log("action", "telex: discarded " .. msgid .. " from <" .. msg.from .. "> to <" .. msg.to .. ">") + announce.admins("discarded " .. msgid .. "from <" .. msg.from .. "> to <" .. msg.to .. ">") return end @@ -260,8 +260,8 @@ function telex.retour(msgid) telex.save_msg(msgid2, msg) telex.deliver(msgid2, msg) - minetest.log("action", "telex: returned a message from <" .. from .. "> back to <" .. to .. ">") - announce.admins("returned a message from <" .. from .. "> back to <" .. to .. ">") + minetest.log("action", "telex: returned " .. msgid .. " -> " .. msgid2 .. " from <" .. from .. "> back to <" .. to .. ">") + announce.admins("returned " .. msgid .. " -> " .. msgid2 .. " from <" .. from .. "> back to <" .. to .. ">") end -- returns message/mbox --FIXME compress/decompress -- 2.11.4.GIT