Commit b6586665 authored by Mario Sanchez Prada's avatar Mario Sanchez Prada Committed by Commit Bot

Fix declaration of override method in IdentityManagerObserverBridge

IdentityManager::OnRefreshTokenRemovedForAccount() expects as a first
parameter a "const std::string&" instead of a "const AccountInfo&",
so this patch fixes it to prevent build failures when using this API
because of OnRefreshTokenRemovedForAccount(const AccountInfo&) not
being a valid override for the virtual method declared.

Bug: 903391
Change-Id: I46cd6778240a40af6863ca7fd3b8d9a88e735fde
Reviewed-on: https://chromium-review.googlesource.com/c/1327161Reviewed-by: default avatarColin Blundell <blundell@chromium.org>
Commit-Queue: Mario Sanchez Prada <mario@igalia.com>
Cr-Commit-Position: refs/heads/master@{#606787}
parent de3b8c8d
......@@ -26,7 +26,7 @@
- (void)onPrimaryAccountCleared:(const AccountInfo&)previousPrimaryAccountInfo;
- (void)onRefreshTokenUpdatedForAccount:(const AccountInfo&)accountInfo
valid:(BOOL)isValid;
- (void)onRefreshTokenRemovedForAccount:(const AccountInfo&)accountInfo;
- (void)onRefreshTokenRemovedForAccount:(const std::string&)accountId;
- (void)onAccountsInCookieUpdated:(const std::vector<AccountInfo>&)accounts;
@end
......@@ -48,8 +48,7 @@ class IdentityManagerObserverBridge : public IdentityManager::Observer {
const AccountInfo& previous_primary_account_info) override;
void OnRefreshTokenUpdatedForAccount(const AccountInfo& account_info,
bool is_valid) override;
void OnRefreshTokenRemovedForAccount(
const AccountInfo& account_info) override;
void OnRefreshTokenRemovedForAccount(const std::string& account_id) override;
void OnAccountsInCookieUpdated(
const std::vector<AccountInfo>& accounts) override;
......
......@@ -45,10 +45,10 @@ void IdentityManagerObserverBridge::OnRefreshTokenUpdatedForAccount(
}
void IdentityManagerObserverBridge::OnRefreshTokenRemovedForAccount(
const AccountInfo& account_info) {
const std::string& account_id) {
if ([delegate_
respondsToSelector:@selector(onRefreshTokenRemovedForAccount:)]) {
[delegate_ onRefreshTokenRemovedForAccount:account_info];
[delegate_ onRefreshTokenRemovedForAccount:account_id];
}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment