Index: chrome/browser/profiles/avatar_menu_desktop.cc |
diff --git a/chrome/browser/profiles/avatar_menu_desktop.cc b/chrome/browser/profiles/avatar_menu_desktop.cc |
index 35949a5ef7ec71e3733745a0633c68251d9654ab..117a1cf4de354e71e3bac123ece1e518885680fe 100644 |
--- a/chrome/browser/profiles/avatar_menu_desktop.cc |
+++ b/chrome/browser/profiles/avatar_menu_desktop.cc |
@@ -15,14 +15,15 @@ void AvatarMenu::GetImageForMenuButton(Profile* profile, |
bool* is_rectangle) { |
ProfileInfoCache& cache = |
g_browser_process->profile_manager()->GetProfileInfoCache(); |
- size_t index = cache.GetIndexOfProfileWithPath(profile->GetPath()); |
- if (index == std::string::npos) { |
+ |
+ ProfileInfoEntry entry; |
+ if (!cache.GetInfoForProfile(profile->GetPath(), &entry)) { |
NOTREACHED(); |
return; |
} |
- *image = cache.GetAvatarIconOfProfileAtIndex(index); |
+ *image = cache.GetAvatarIconOfProfile(entry.path()); |
*is_rectangle = |
- cache.IsUsingGAIAPictureOfProfileAtIndex(index) && |
- cache.GetGAIAPictureOfProfileAtIndex(index); |
+ entry.is_using_GAIA_picture() && |
+ cache.GetGAIAPictureOfProfile(entry.path()); |
} |