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

Side by Side Diff: components/signin/core/browser/about_signin_internals.cc

Issue 1094103005: Profile chooser on mac was passing wrong value to signin error controller. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix ASI Created 5 years, 8 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "components/signin/core/browser/about_signin_internals.h" 5 #include "components/signin/core/browser/about_signin_internals.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/hash.h" 8 #include "base/hash.h"
9 #include "base/i18n/time_formatting.h" 9 #include "base/i18n/time_formatting.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 528 matching lines...) Expand 10 before | Expand all | Expand 10 after
539 account_id); 539 account_id);
540 AddSectionEntry(basic_info, 540 AddSectionEntry(basic_info,
541 SigninStatusFieldToLabel( 541 SigninStatusFieldToLabel(
542 static_cast<UntimedSigninStatusField>(GAIA_ID)), 542 static_cast<UntimedSigninStatusField>(GAIA_ID)),
543 account_tracker->GetAccountInfo(account_id).gaia); 543 account_tracker->GetAccountInfo(account_id).gaia);
544 AddSectionEntry(basic_info, 544 AddSectionEntry(basic_info,
545 SigninStatusFieldToLabel( 545 SigninStatusFieldToLabel(
546 static_cast<UntimedSigninStatusField>(USERNAME)), 546 static_cast<UntimedSigninStatusField>(USERNAME)),
547 signin_manager->GetAuthenticatedUsername()); 547 signin_manager->GetAuthenticatedUsername());
548 if (signin_error_controller->HasError()) { 548 if (signin_error_controller->HasError()) {
549 std::string error_account_id =
Mike Lerman 2015/04/24 19:36:26 nit: Can this and just below be const std::string&
Roger Tawa OOO till Jul 10th 2015/04/27 20:31:59 Done.
550 signin_error_controller->error_account_id();
551 std::string error_username =
552 account_tracker->GetAccountInfo(error_account_id).email;
549 AddSectionEntry(basic_info, "Auth Error", 553 AddSectionEntry(basic_info, "Auth Error",
550 signin_error_controller->auth_error().ToString()); 554 signin_error_controller->auth_error().ToString());
551 AddSectionEntry(basic_info, "Auth Error Username", 555 AddSectionEntry(basic_info, "Auth Error Account Id", error_account_id);
552 signin_error_controller->error_username()); 556 AddSectionEntry(basic_info, "Auth Error Username", error_username);
553 } else { 557 } else {
554 AddSectionEntry(basic_info, "Auth Error", "None"); 558 AddSectionEntry(basic_info, "Auth Error", "None");
555 } 559 }
556 } 560 }
557 561
558 #if !defined(OS_CHROMEOS) 562 #if !defined(OS_CHROMEOS)
559 // TODO(robliao): Remove ScopedTracker below once https://crbug.com/422460 is 563 // TODO(robliao): Remove ScopedTracker below once https://crbug.com/422460 is
560 // fixed. 564 // fixed.
561 tracked_objects::ScopedTracker tracking_profile3( 565 tracked_objects::ScopedTracker tracking_profile3(
562 FROM_HERE_WITH_EXPLICIT_FUNCTION( 566 FROM_HERE_WITH_EXPLICIT_FUNCTION(
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
629 } 633 }
630 634
631 for(const std::string& account_id : accounts_in_token_service) { 635 for(const std::string& account_id : accounts_in_token_service) {
632 base::DictionaryValue* entry = new base::DictionaryValue(); 636 base::DictionaryValue* entry = new base::DictionaryValue();
633 entry->SetString("accountId", account_id); 637 entry->SetString("accountId", account_id);
634 account_info->Append(entry); 638 account_info->Append(entry);
635 } 639 }
636 640
637 return signin_status.Pass(); 641 return signin_status.Pass();
638 } 642 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698