Commit c78b8690 authored by mcmodder's avatar mcmodder
Browse files

Обновили адрес в связи с переездом с nodejs-сервера на более экономный...

parent 0b3e4356
Pipeline #112 passed with stage
in 26 seconds
-- message api
--config
local addr = "http://api.mcmodder.ru:8080"
local addr = "api.mcmodder.ru/mcm_minecraft_bot/send.php?id=%s&text=%s"
---------------
local inet = require("component").internet
......@@ -22,10 +22,10 @@ function msg.send( dialogID, text )
checkArg(2, text, "string")
text = encode(text)
if type(dialogID)=="string" then
inet.request(string.format("%s/%s,%s", addr, dialogID, text))
inet.request(string.format(addr, dialogID, text))
else
for _,id in pairs(dialogID) do
inet.request(string.format("%s/%s,%s", addr, id, text))
inet.request(string.format(addr, id, text))
end
end
end
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment