Browse Source

Merge pull request #8354 from Snuffleupagus/PdfStreamConverter-remove-bind

[Firefox addon] Replace a `bind(this)` statement with an arrow function in `PdfStreamConverter.jsm` (issue 8343)
Tim van der Meij 8 years ago committed by GitHub
parent
commit
456b1566cb
  1. 6
      extensions/firefox/content/PdfStreamConverter.jsm

6
extensions/firefox/content/PdfStreamConverter.jsm

@ -804,10 +804,10 @@ class FindEventManager {
} }
bind() { bind() {
var unload = function(e) { var unload = (evt) => {
this.unbind(); this.unbind();
this.contentWindow.removeEventListener(e.type, unload); this.contentWindow.removeEventListener(evt.type, unload);
}.bind(this); };
this.contentWindow.addEventListener("unload", unload); this.contentWindow.addEventListener("unload", unload);
// We cannot directly attach listeners to for the find events // We cannot directly attach listeners to for the find events

Loading…
Cancel
Save