зеркало из https://github.com/mozilla/gecko-dev.git
Bug 986544 - Don't try to parse searchplugins list as XML. r=rnewman
XHR requests default to text/xml. This just avoids trying to interpret list.txt as XML.
This commit is contained in:
Родитель
62b6df7d3c
Коммит
d84d5b2511
|
@ -3674,6 +3674,7 @@ SearchService.prototype = {
|
|||
let deferred = Promise.defer();
|
||||
let request = Cc["@mozilla.org/xmlextras/xmlhttprequest;1"].
|
||||
createInstance(Ci.nsIXMLHttpRequest);
|
||||
request.overrideMimeType("text/plain");
|
||||
request.onload = function(aEvent) {
|
||||
deferred.resolve(aEvent.target.responseText);
|
||||
};
|
||||
|
|
Загрузка…
Ссылка в новой задаче