Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(818)

Unified Diff: chrome/browser/android/profiles/profile_downloader_android.cc

Issue 339223003: [Mirror] Fix wrong logic in GetCachedNameForPrimaryAccount (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/android/profiles/profile_downloader_android.cc
diff --git a/chrome/browser/android/profiles/profile_downloader_android.cc b/chrome/browser/android/profiles/profile_downloader_android.cc
index b49a808d1f704fc90c6ac0ae83171b69c07b2f63..c6d4785fd1cec985a05acbbe5377fe369b89feff 100644
--- a/chrome/browser/android/profiles/profile_downloader_android.cc
+++ b/chrome/browser/android/profiles/profile_downloader_android.cc
@@ -116,13 +116,8 @@ jstring GetCachedNameForPrimaryAccount(JNIEnv* env,
const size_t index = info.GetIndexOfProfileWithPath(profile->GetPath());
base::string16 name;
-
- if (index != std::string::npos &&
- !info.ProfileIsUsingDefaultNameAtIndex(index)) {
+ if (index != std::string::npos)
name = info.GetGAIANameOfProfileAtIndex(index);
- if (name.empty())
- name = info.GetNameOfProfileAtIndex(index);
- }
return base::android::ConvertUTF16ToJavaString(env, name).Release();
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698