small fix
This commit is contained in:
@@ -21,9 +21,9 @@ function on_alarm()
|
|||||||
end
|
end
|
||||||
|
|
||||||
local key = aio:get_args()[1]
|
local key = aio:get_args()[1]
|
||||||
local body = "api_key="..key.."&format=json"
|
local body = "api_key="..key.."&format=json"
|
||||||
|
|
||||||
http:post(api_url.."getMonitors", body, media_type)
|
http:post(api_url.."getMonitors", body, media_type)
|
||||||
end
|
end
|
||||||
|
|
||||||
function on_click()
|
function on_click()
|
||||||
@@ -35,7 +35,7 @@ function on_click()
|
|||||||
end
|
end
|
||||||
|
|
||||||
function on_network_result(result)
|
function on_network_result(result)
|
||||||
local parsed = json.decode(result)
|
local parsed = json.decode(result)
|
||||||
|
|
||||||
if (parsed.stat ~= "ok") then
|
if (parsed.stat ~= "ok") then
|
||||||
ui:show_text("Error: "..parsed.error.message)
|
ui:show_text("Error: "..parsed.error.message)
|
||||||
|
|||||||
Reference in New Issue
Block a user