browser.notifications.onClicked callback get erroneous second parameter

NEW
Assigned to

Status

()

Toolkit
WebExtensions: Compatibility
P5
minor
9 months ago
9 months ago

People

(Reporter: nmaier, Assigned: mstriemer)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

9 months ago
A browser.notifications.onClicked callback is supposed to get called with a single parameter, (notificationId) while in fact it gets called with two parameters (notificationId, true)[0].
This seems to be a copypaste mistake (copying onClosed).

I ran into this when registering onClicked/onButtonClicked to the same listener function, expecting the second parameter to be either a button index (well, not in Firefox, no buttons yet) or undefined .


[0] https://hg.mozilla.org/mozilla-central/annotate/f91054a848d6/toolkit/components/extensions/ext-notifications.js#l135
Flags: needinfo?(bob.silverberg)

Updated

9 months ago
Priority: -- → P5
Yes, this looks like a bug and a simple one to fix. I'll take it.
Assignee: nobody → bob.silverberg
Flags: needinfo?(bob.silverberg)
(Assignee)

Updated

9 months ago
Assignee: bob.silverberg → mstriemer
You need to log in before you can comment on or make changes to this bug.