Skip to content

Local notifications plugin doesn't work with Canvas+ #4

Description

@Jack37

When I use local notifications plugin, the notification object is not received by plugin with same values as it is sent from Cocoon. Because of this, notifications don’t arrive at correct time. There is no such problem with Webview, only Canvas+.

Example of wrong data:
at: 123456789 is received as at: 123457
at: 1023456789 is received as at: 1023460
at: 1530878173223 is received as at: 1530880000
color: null is received as color: "null"

As you can see, the time property at gets rounded to 6 places, and few zeros are added to the end.

The color property is from different notification plugin, but it’s value is sent as null from Cocoon, and is received as "null" string by the plugin. This causes crash because null check is skipped. As stated before, this only happens with Canvas+ engine, not Webview.

Temporary solution is to send the notification date as string, not as long.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions