| Index: chrome/browser/autofill/autofill_download.cc
|
| diff --git a/chrome/browser/autofill/autofill_download.cc b/chrome/browser/autofill/autofill_download.cc
|
| index ebb0074e5985e5c9a963bf7573d330c11dcd2b40..394ca7fc9a61d8f0c2b59134c097f42fec74200c 100644
|
| --- a/chrome/browser/autofill/autofill_download.cc
|
| +++ b/chrome/browser/autofill/autofill_download.cc
|
| @@ -18,6 +18,7 @@
|
| #include "chrome/browser/autofill/autofill_xml_parser.h"
|
| #include "chrome/browser/autofill/form_structure.h"
|
| #include "chrome/common/pref_names.h"
|
| +#include "components/user_prefs/user_prefs.h"
|
| #include "content/public/browser/browser_context.h"
|
| #include "googleurl/src/gurl.h"
|
| #include "net/base/load_flags.h"
|
| @@ -70,8 +71,7 @@ AutofillDownloadManager::AutofillDownloadManager(BrowserContext* context,
|
| negative_upload_rate_(0),
|
| fetcher_id_for_unittest_(0) {
|
| DCHECK(observer_);
|
| - PrefService* preferences =
|
| - PrefServiceFromBrowserContext(browser_context_);
|
| + PrefService* preferences = components::UserPrefs::Get(browser_context_);
|
| positive_upload_rate_ =
|
| preferences->GetDouble(prefs::kAutofillPositiveUploadRate);
|
| negative_upload_rate_ =
|
| @@ -160,8 +160,7 @@ void AutofillDownloadManager::SetPositiveUploadRate(double rate) {
|
| positive_upload_rate_ = rate;
|
| DCHECK_GE(rate, 0.0);
|
| DCHECK_LE(rate, 1.0);
|
| - PrefService* preferences = PrefServiceFromBrowserContext(
|
| - browser_context_);
|
| + PrefService* preferences = components::UserPrefs::Get(browser_context_);
|
| preferences->SetDouble(prefs::kAutofillPositiveUploadRate, rate);
|
| }
|
|
|
| @@ -171,8 +170,7 @@ void AutofillDownloadManager::SetNegativeUploadRate(double rate) {
|
| negative_upload_rate_ = rate;
|
| DCHECK_GE(rate, 0.0);
|
| DCHECK_LE(rate, 1.0);
|
| - PrefService* preferences = PrefServiceFromBrowserContext(
|
| - browser_context_);
|
| + PrefService* preferences = components::UserPrefs::Get(browser_context_);
|
| preferences->SetDouble(prefs::kAutofillNegativeUploadRate, rate);
|
| }
|
|
|
|
|