File tree Expand file tree Collapse file tree 1 file changed +3
-7
lines changed Expand file tree Collapse file tree 1 file changed +3
-7
lines changed Original file line number Diff line number Diff line change @@ -122,16 +122,12 @@ const EventTarget = {
122
122
* @param {Function } listener The listener to add
123
123
* @param {Object } [options] An options object specifies characteristics about
124
124
* the event listener
125
- * @param {Boolean } [options.once=false] A `Boolean`` indicating that the
125
+ * @param {Boolean } [options.once=false] A `Boolean` indicating that the
126
126
* listener should be invoked at most once after being added. If `true`,
127
127
* the listener would be automatically removed when invoked.
128
128
* @public
129
129
*/
130
- addEventListener (
131
- type ,
132
- listener ,
133
- options = { once : false , [ kForOnEventAttribute ] : false }
134
- ) {
130
+ addEventListener ( type , listener , options = { } ) {
135
131
let wrapper ;
136
132
137
133
if ( type === 'message' ) {
@@ -155,7 +151,7 @@ const EventTarget = {
155
151
return ;
156
152
}
157
153
158
- wrapper [ kForOnEventAttribute ] = options [ kForOnEventAttribute ] ;
154
+ wrapper [ kForOnEventAttribute ] = ! ! options [ kForOnEventAttribute ] ;
159
155
wrapper [ kListener ] = listener ;
160
156
161
157
if ( options . once ) {
You can’t perform that action at this time.
0 commit comments