Bug 1621353 - Map yandex distribution IDs. r=mixedpuppy

Differential Revision: https://phabricator.services.mozilla.com/D67331

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Michael Kaply 2020-03-18 17:42:13 +00:00
Родитель fce38bc562
Коммит 56dcdec502
1 изменённых файлов: 16 добавлений и 0 удалений

Просмотреть файл

@ -442,6 +442,22 @@ DistributionCustomizer.prototype = {
}
}
if (this._ini.getString("Global", "id") == "yandex") {
// All yandex distributions have the same distribution ID,
// so we're using an internal preference to name them correctly.
// This is needed for search to work properly.
try {
defaults.set(
"distribution.id",
defaults
.get("extensions.yasearch@yandex.ru.clids.vendor")
.replace("firefox", "yandex")
);
} catch (e) {
// Just use the default distribution ID.
}
}
let localizedStr = Cc["@mozilla.org/pref-localizedstring;1"].createInstance(
Ci.nsIPrefLocalizedString
);