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

Unified Diff: chrome/browser/chromeos/preferences.cc

Issue 11649055: OAuth2 sign-in flow for ChromeOS (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 11 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
Index: chrome/browser/chromeos/preferences.cc
diff --git a/chrome/browser/chromeos/preferences.cc b/chrome/browser/chromeos/preferences.cc
index 9316186938dd0df9701de01bc7384cedb60d3d2b..8268cc45cb4f45214207aa0e43bd28a72cb9d5a3 100644
--- a/chrome/browser/chromeos/preferences.cc
+++ b/chrome/browser/chromeos/preferences.cc
@@ -276,13 +276,15 @@ void Preferences::RegisterUserPrefs(PrefServiceSyncable* prefs) {
"0.0.0.0",
PrefServiceSyncable::SYNCABLE_PREF);
- // OAuth1 all access token and secret pair.
- prefs->RegisterStringPref(prefs::kOAuth1Token,
- "",
- PrefServiceSyncable::UNSYNCABLE_PREF);
- prefs->RegisterStringPref(prefs::kOAuth1Secret,
- "",
- PrefServiceSyncable::UNSYNCABLE_PREF);
+ if (!CommandLine::ForCurrentProcess()->HasSwitch(switches::kForceOAuth2)) {
+ // Legacy OAuth1 all access token and secret pair.
+ prefs->RegisterStringPref(prefs::kOAuth1Token,
+ "",
+ PrefServiceSyncable::UNSYNCABLE_PREF);
+ prefs->RegisterStringPref(prefs::kOAuth1Secret,
+ "",
+ PrefServiceSyncable::UNSYNCABLE_PREF);
+ }
// TODO(wad): Once UI is connected, a final default can be set. At that point
// change this pref from UNSYNCABLE to SYNCABLE.

Powered by Google App Engine
This is Rietveld 408576698