mirror of
https://github.com/antos-rde/antosdk-apps.git
synced 2025-07-13 06:04:26 +02:00
adapt Blogger to the new api
This commit is contained in:
@ -1,6 +1,8 @@
|
||||
|
||||
local data = ...
|
||||
print(data.content)
|
||||
-- print(data.content)
|
||||
local error_msg = {}
|
||||
local iserror = false
|
||||
for k,v in pairs(data.to) do
|
||||
print("sent to:"..v)
|
||||
local to = v
|
||||
@ -11,7 +13,12 @@ for k,v in pairs(data.to) do
|
||||
--print(cmd)
|
||||
local r = os.execute(cmd)
|
||||
if not r then
|
||||
print("Cannot send mail to: "..v)
|
||||
iserror = true
|
||||
table.insert(error_msg, v)
|
||||
print("Unable to send mail to: "..v)
|
||||
end
|
||||
end
|
||||
return "Email sent"
|
||||
local result = {}
|
||||
result.error = iserror
|
||||
result.result = error_msg
|
||||
return result
|
Reference in New Issue
Block a user