Bug 1176381 - Fix a typo in SearchSuggestionController that causes a JS warning. r=MattN
authorDrew Willcoxon <adw@mozilla.com>
Tue, 23 Jun 2015 17:42:19 -0700
changeset 268090 c4ad3f0a514349daca322894e51eda237efaf137
parent 268089 8a3519734f64b6b3aca630835ee8a8147e6cbfd7
child 268091 2b391a831518764b800381e8eda7a8a6d58cbc6a
push id4932
push userjlund@mozilla.com
push dateMon, 10 Aug 2015 18:23:06 +0000
treeherdermozilla-esr52@6dd5a4f5f745 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersMattN
bugs1176381
milestone41.0a1
Bug 1176381 - Fix a typo in SearchSuggestionController that causes a JS warning. r=MattN
toolkit/components/search/SearchSuggestionController.jsm
--- a/toolkit/components/search/SearchSuggestionController.jsm
+++ b/toolkit/components/search/SearchSuggestionController.jsm
@@ -123,17 +123,17 @@ this.SearchSuggestionController.prototyp
       throw new Error("The privateMode argument is required to avoid unintentional privacy leaks");
     }
     if (!(engine instanceof Ci.nsISearchEngine)) {
       throw new Error("Invalid search engine");
     }
     if (!this.maxLocalResults && !this.maxRemoteResults) {
       throw new Error("Zero results expected, what are you trying to do?");
     }
-    if (this.maxLocalResults < 0 || this.remoteResult < 0) {
+    if (this.maxLocalResults < 0 || this.maxRemoteResults < 0) {
       throw new Error("Number of requested results must be positive");
     }
 
     // Array of promises to resolve before returning results.
     let promises = [];
     this._searchString = searchTerm;
 
     // Remote results