From 57bbb175bfed6388f63566230eb7f1a591107855 Mon Sep 17 00:00:00 2001 From: bobzel Date: Wed, 12 Aug 2020 16:10:39 -0400 Subject: fixed run-time warnings & remove print statements --- src/client/views/search/SearchBox.tsx | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) (limited to 'src/client/views/search') diff --git a/src/client/views/search/SearchBox.tsx b/src/client/views/search/SearchBox.tsx index b1ddeb08b..9cd03d518 100644 --- a/src/client/views/search/SearchBox.tsx +++ b/src/client/views/search/SearchBox.tsx @@ -339,7 +339,6 @@ export class SearchBox extends ViewBoxBaseComponent; getResults = async (query: string) => { - console.log("Get"); if (this.lockPromise) { await this.lockPromise; } @@ -632,7 +630,6 @@ export class SearchBox extends ViewBoxBaseComponent highlighting[doc[Id]]); const lines = new Map(); @@ -644,18 +641,15 @@ export class SearchBox extends ViewBoxBaseComponent { filteredDocs.forEach((doc, i) => { - console.log(i); const index = this._resultsSet.get(doc); const highlight = highlights[doc[Id]]; const line = lines.get(doc[Id]) || []; const hlights = highlight ? Object.keys(highlight).map(key => key.substring(0, key.length - 2)).filter(k => k) : []; - doc ? console.log(Cast(doc.context, Doc)) : null; // if (this.findCommonElements(hlights)) { // } if (index === undefined) { this._resultsSet.set(doc, this._results.length); this._results.push([doc, hlights, line]); - console.log(i); } else { this._results[index][1].push(...hlights); this._results[index][2].push(...line); @@ -755,7 +749,7 @@ export class SearchBox extends ViewBoxBaseComponent(["title", "author", "text", "type", "data", "*lastModified"]); + const headers = new Set(["title", "author", "text", "type", "data", "*lastModified", "context"]); // if ((this._numTotalResults === 0 || this._results.length === 0) && this._openNoResults) { // if (this.noresults === "") { // this.noresults = "No search results :("; -- cgit v1.2.3-70-g09d2