mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-29 15:47:57 +02:00
Replace unnecessary bind(this)
statements with arrow functions in web/
files
By using `let`, which is block-scoped, instead of `var` in a couple of places we're able to get rid of additional `bind` calls.
This commit is contained in:
parent
3adda80f97
commit
f27b5013e2
12 changed files with 53 additions and 57 deletions
|
@ -277,7 +277,7 @@ var PDFFindController = (function PDFFindControllerClosure() {
|
|||
this.state = state;
|
||||
this.updateUIState(FindStates.FIND_PENDING);
|
||||
|
||||
this._firstPagePromise.then(function() {
|
||||
this._firstPagePromise.then(() => {
|
||||
this.extractText();
|
||||
|
||||
clearTimeout(this.findTimeout);
|
||||
|
@ -287,7 +287,7 @@ var PDFFindController = (function PDFFindControllerClosure() {
|
|||
} else {
|
||||
this.nextMatch();
|
||||
}
|
||||
}.bind(this));
|
||||
});
|
||||
},
|
||||
|
||||
updatePage: function PDFFindController_updatePage(index) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue