Skip to content

introConfirmation switch does not work #10

@obagley

Description

@obagley

Hello,

Thanks for the great extension, I hope it will be released soon!

In the meantime - a minor defect for your consideration. Currently the modal dialog switch doesn't work, the intro is shown regardless of the switch state. I debugged it briefly, the problem is that the localStorage.pushConfirmation is not initialized outside of the showIntroConfirmation() function.

Therefore on the first execution this check
if (pushNotifications.introConfirmation && !localStorage.pushConfirmation)
is working with pushNotifications.introConfirmation = 0 (correctly passed from the config) and localStorage.pushConfirmation = undefined (wrong, should be initialized to 0 somewhere).

I'm not an expert in java script, seems a bit funny to me - when the IF condition is not defined, the IF statement is executed.

Should be easy enough to fix.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions