Update to support email

This commit is contained in:
rubenwardy 2015-12-18 22:34:14 +00:00
parent 03441a5fee
commit 49c880c2f6
2 changed files with 3 additions and 7 deletions

View File

@ -1 +1 @@
chatplus
email

View File

@ -1,7 +1,3 @@
if not chatplus.send_mail then
error("You need to update chatplus!")
end
minetest.register_chatcommand("report", {
func = function(name, param)
param = param:trim()
@ -28,11 +24,11 @@ minetest.register_chatcommand("report", {
if #mods > 0 then
mod_list = table.concat(mods, ", ")
chatplus.send_mail(name, minetest.setting_get("name"),
email.send_mail(name, minetest.setting_get("name"),
"Report: " .. param .. " (mods online: " .. mod_list .. ")")
return true, "Reported. Moderators currently online: " .. mod_list
else
chatplus.send_mail(name, minetest.setting_get("name"),
email.send_mail(name, minetest.setting_get("name"),
"Report: " .. param .. " (no mods online)")
return true, "Reported. We'll get back to you."
end