Closed
Bug 1333386
Opened 8 years ago
Closed 8 years ago
Use {once: true} for window "load" event listener
Categories
(Firefox for Android Graveyard :: General, defect)
Tracking
(firefox54 fixed)
RESOLVED
FIXED
Firefox 54
Tracking | Status | |
---|---|---|
firefox54 | --- | fixed |
People
(Reporter: JanH, Assigned: JanH)
References
Details
Attachments
(1 file)
I've learnt about this only after the landing of bug 1332863 was already in progress - instead of removing the listener from within its own function, we can now simply call addEventListener with {once: true}, which also means we don't have to worry any more about storing a reference to the function.
Because it looks like this won't be covered by the automatic conversion in bug 1331599 [1], I'll do it separately instead.
[1] Because I'm using an arrow function to avoid having to rebind "this", I have to capture the listener into a variable before adding it, so I have a function reference I can later call removeEventListener with.
Comment hidden (mozreview-request) |
Comment 2•8 years ago
|
||
mozreview-review |
Comment on attachment 8830474 [details]
Bug 1333386 - Use {once: true} for session store window "load" listener.
https://reviewboard.mozilla.org/r/107228/#review108518
Attachment #8830474 -
Flags: review?(s.kaspari) → review+
Assignee | ||
Comment 3•8 years ago
|
||
Keywords: checkin-needed
Pushed by cbook@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/7a041cbe31bb
Use {once: true} for session store window "load" listener. r=sebastian
Keywords: checkin-needed
Comment 5•8 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 8 years ago
status-firefox54:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → Firefox 54
Updated•4 years ago
|
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•