| Index: chrome/browser/signin/token_service.cc
|
| diff --git a/chrome/browser/signin/token_service.cc b/chrome/browser/signin/token_service.cc
|
| index 2367348cc12dea946a83fe3e1f687bba289975f6..f402316d0c21edf60f54c172e13155e2217000d8 100644
|
| --- a/chrome/browser/signin/token_service.cc
|
| +++ b/chrome/browser/signin/token_service.cc
|
| @@ -158,6 +158,21 @@ void TokenService::UpdateCredentialsWithOAuth2(
|
| SaveOAuth2Credentials(oauth2_tokens);
|
| }
|
|
|
| +void TokenService::ClearOAuth2Credentials() {
|
| + token_map_.erase(GaiaConstants::kGaiaOAuth2LoginRefreshToken);
|
| + if (token_web_data_.get()) {
|
| + token_web_data_->RemoveTokenForService(
|
| + GaiaConstants::kGaiaOAuth2LoginRefreshToken);
|
| + }
|
| +
|
| + FOR_DIAGNOSTICS_OBSERVERS(
|
| + NotifyClearStoredToken(GaiaConstants::kGaiaOAuth2LoginRefreshToken));
|
| +
|
| + FireTokenRequestFailedNotification(
|
| + GaiaConstants::kGaiaOAuth2LoginRefreshToken,
|
| + GoogleServiceAuthError(GoogleServiceAuthError::INVALID_GAIA_CREDENTIALS));
|
| +}
|
| +
|
| void TokenService::LoadTokensFromDB() {
|
| DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
|
| if (token_web_data_.get())
|
|
|