зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1313731 - Append /v1 to fxaccount's autoconfig's auth_server_base_url if not present r=rfkelly
Currently the fxaccounts content server passes this through directly from its configuration files, and accepts this as either containing the trailing /v1 or not. On stage, it contains it, but on dev it does not. In the near future, it should be possible to append the trailing /v1 unconditionally, as the FxA content server is being changed to never send it down (which will be consistent with the other prefs), however it's done conditionally as to not break autoconfig against stage in the mean time. MozReview-Commit-ID: AStTm2hHVHQ --HG-- extra : rebase_source : bf98cef357d5834e08a01b3c233a8ccb37243e64
This commit is contained in:
Родитель
2de2f42926
Коммит
a0412a141a
|
@ -144,7 +144,11 @@ this.FxAccountsConfig = {
|
|||
try {
|
||||
// Update the prefs directly specified by the config.
|
||||
let config = JSON.parse(jsonStr)
|
||||
Services.prefs.setCharPref("identity.fxaccounts.auth.uri", config.auth_server_base_url);
|
||||
let authServerBase = config.auth_server_base_url;
|
||||
if (!authServerBase.endsWith("/v1")) {
|
||||
authServerBase += "/v1";
|
||||
}
|
||||
Services.prefs.setCharPref("identity.fxaccounts.auth.uri", authServerBase);
|
||||
Services.prefs.setCharPref("identity.fxaccounts.remote.oauth.uri", config.oauth_server_base_url + "/v1");
|
||||
Services.prefs.setCharPref("identity.fxaccounts.remote.profile.uri", config.profile_server_base_url + "/v1");
|
||||
Services.prefs.setCharPref("identity.sync.tokenserver.uri", config.sync_tokenserver_base_url + "/1.0/sync/1.5");
|
||||
|
|
Загрузка…
Ссылка в новой задаче