I was checking out the push notifications extension and I scheduled some notifications but they aren’t shown as scheduled and they only show at the same time immediately the app is reopened.
local function push_listener(self, payload, origin)
-- The payload arrives here.
end
function init(self)
push.set_listener(push_listener)
local payload = '{ "data" : { "field" : "Some value", "field2" : "Other value" } }'
id1, err1 = push.schedule(3000, "First Notification", "This is the first notification", payload)
id2, err2 = push.schedule(6000, "Second Notification", "This is the second notification", payload)
id3, err3 = push.schedule(9000, "Third Notification", "This is the third notification", payload)
end