From 21d959bb82c838d8662a493f40768ae1ebd0caa2 Mon Sep 17 00:00:00 2001 From: Tim van der Meij Date: Tue, 11 Sep 2018 20:01:50 +0200 Subject: [PATCH] Remove unused member variable `hadMatch` from the find controller It's only being assigned, but not read anymore. --- web/pdf_find_controller.js | 3 --- 1 file changed, 3 deletions(-) diff --git a/web/pdf_find_controller.js b/web/pdf_find_controller.js index e23068601..a4754265f 100644 --- a/web/pdf_find_controller.js +++ b/web/pdf_find_controller.js @@ -368,7 +368,6 @@ class PDFFindController { this.selected.pageIdx = this.selected.matchIdx = -1; this.offset.pageIdx = currentPageIndex; this.offset.matchIdx = null; - this.hadMatch = false; this.resumePageIdx = null; this.pageMatches = []; this.matchesCountTotal = 0; @@ -411,7 +410,6 @@ class PDFFindController { (previous && offset.matchIdx > 0)) { // The simple case; we just have advance the matchIdx to select // the next match on the page. - this.hadMatch = true; offset.matchIdx = (previous ? offset.matchIdx - 1 : offset.matchIdx + 1); this._updateMatch(/* found = */ true); @@ -432,7 +430,6 @@ class PDFFindController { if (numMatches) { // There were matches for the page, so initialize `matchIdx`. - this.hadMatch = true; offset.matchIdx = (previous ? numMatches - 1 : 0); this._updateMatch(/* found = */ true); return true;