diff --git a/browser/components/preferences/in-content/search.js b/browser/components/preferences/in-content/search.js index 9fd1c479a393..f9a814f76166 100644 --- a/browser/components/preferences/in-content/search.js +++ b/browser/components/preferences/in-content/search.js @@ -343,6 +343,11 @@ EngineStore.prototype = { this.moveEngine(this._getEngineByName(e.name), i); } else { // Otherwise, add it back to our internal store + + // The search service removes the alias when an engine is hidden, + // so clear any alias we may have cached before unhiding the engine. + e.alias = ""; + this._engines.splice(i, 0, e); let engine = e.originalEngine; engine.hidden = false; diff --git a/browser/components/preferences/search.js b/browser/components/preferences/search.js index 250c6ca640e4..9af4068c2702 100644 --- a/browser/components/preferences/search.js +++ b/browser/components/preferences/search.js @@ -372,6 +372,11 @@ EngineStore.prototype = { this.moveEngine(this._getEngineByName(e.name), i); } else { // Otherwise, add it back to our internal store + + // The search service removes the alias when an engine is hidden, + // so clear any alias we may have cached before unhiding the engine. + e.alias = ""; + this._engines.splice(i, 0, e); this._ops.push(new EngineUnhideOp(e, i)); added++;