mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-04 04:58:00 +00:00
Bug 1207840 - add '?service=sync' to the URL used when disconnecting from Sync. r=zaach
This commit is contained in:
parent
6ccc2beafb
commit
639d6c6d42
@ -653,7 +653,10 @@ FxAccountsInternal.prototype = {
|
||||
},
|
||||
|
||||
_signOutServer: function signOutServer(sessionToken) {
|
||||
return this.fxAccountsClient.signOut(sessionToken);
|
||||
// For now we assume the service being logged out from is Sync - we might
|
||||
// need to revisit this when this FxA code is used in a context that
|
||||
// isn't Sync.
|
||||
return this.fxAccountsClient.signOut(sessionToken, {service: "sync"});
|
||||
},
|
||||
|
||||
/**
|
||||
|
@ -167,8 +167,12 @@ this.FxAccountsClient.prototype = {
|
||||
* The session token encoded in hex
|
||||
* @return Promise
|
||||
*/
|
||||
signOut: function (sessionTokenHex) {
|
||||
return this._request("/session/destroy", "POST",
|
||||
signOut: function (sessionTokenHex, options = {}) {
|
||||
let path = "/session/destroy";
|
||||
if (options.service) {
|
||||
path += "?service=" + options.service;
|
||||
}
|
||||
return this._request(path, "POST",
|
||||
deriveHawkCredentials(sessionTokenHex, "sessionToken"));
|
||||
},
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user