| Index: chrome/browser/signin/profile_oauth2_token_service.cc
|
| diff --git a/chrome/browser/signin/profile_oauth2_token_service.cc b/chrome/browser/signin/profile_oauth2_token_service.cc
|
| index 6c00938c6acde13cdb628931cba2d4e0ba0954c3..7dbab236cfb034afa8c4b9f681316d10b3aab19a 100644
|
| --- a/chrome/browser/signin/profile_oauth2_token_service.cc
|
| +++ b/chrome/browser/signin/profile_oauth2_token_service.cc
|
| @@ -68,8 +68,6 @@ ProfileOAuth2TokenService::~ProfileOAuth2TokenService() {
|
| }
|
|
|
| void ProfileOAuth2TokenService::Initialize(Profile* profile) {
|
| - DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::UI));
|
| -
|
| DCHECK(profile);
|
| DCHECK(!profile_);
|
| profile_ = profile;
|
| @@ -93,6 +91,7 @@ void ProfileOAuth2TokenService::Initialize(Profile* profile) {
|
| }
|
|
|
| void ProfileOAuth2TokenService::Shutdown() {
|
| + DCHECK(profile_) << "Shutdown() called without matching call to Initialize()";
|
| CancelAllRequests();
|
| signin_global_error_->RemoveProvider(this);
|
| GlobalErrorServiceFactory::GetForProfile(profile_)->RemoveGlobalError(
|
| @@ -108,6 +107,10 @@ std::string ProfileOAuth2TokenService::GetRefreshToken() {
|
| return token_service->GetOAuth2LoginRefreshToken();
|
| }
|
|
|
| +net::URLRequestContextGetter* ProfileOAuth2TokenService::GetRequestContext() {
|
| + return profile_->GetRequestContext();
|
| +}
|
| +
|
| void ProfileOAuth2TokenService::UpdateAuthError(
|
| const GoogleServiceAuthError& error) {
|
| // Do not report connection errors as these are not actually auth errors.
|
| @@ -164,10 +167,6 @@ GoogleServiceAuthError ProfileOAuth2TokenService::GetAuthStatus() const {
|
| return last_auth_error_;
|
| }
|
|
|
| -net::URLRequestContextGetter* ProfileOAuth2TokenService::GetRequestContext() {
|
| - return profile_->GetRequestContext();
|
| -}
|
| -
|
| void ProfileOAuth2TokenService::RegisterCacheEntry(
|
| const std::string& refresh_token,
|
| const ScopeSet& scopes,
|
|
|