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

Unified Diff: components/image_fetcher/image_data_fetcher.cc

Issue 2650453002: Add data usage tracking for image fetcher service (Closed)
Patch Set: Fixed treib@ comments Created 3 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
« no previous file with comments | « components/data_use_measurement/core/data_use_user_data.cc ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/image_fetcher/image_data_fetcher.cc
diff --git a/components/image_fetcher/image_data_fetcher.cc b/components/image_fetcher/image_data_fetcher.cc
index 318e755ce653b53e935913b7794aa160ba16e932..708bf3affda5e8027eccded578519c39d67a2ed2 100644
--- a/components/image_fetcher/image_data_fetcher.cc
+++ b/components/image_fetcher/image_data_fetcher.cc
@@ -35,7 +35,7 @@ struct ImageDataFetcher::ImageDataFetcherRequest {
ImageDataFetcher::ImageDataFetcher(
net::URLRequestContextGetter* url_request_context_getter)
: url_request_context_getter_(url_request_context_getter),
- data_use_service_name_(DataUseUserData::NOT_TAGGED),
+ data_use_service_name_(DataUseUserData::IMAGE_FETCHER_UNTAGGED),
next_url_fetcher_id_(0) {}
ImageDataFetcher::~ImageDataFetcher() {}
@@ -51,9 +51,7 @@ void ImageDataFetcher::FetchImageData(
net::URLFetcher::Create(
next_url_fetcher_id_++, url, net::URLFetcher::GET, this);
- if (data_use_service_name_ != DataUseUserData::NOT_TAGGED) {
- DataUseUserData::AttachToFetcher(url_fetcher.get(), data_use_service_name_);
- }
+ DataUseUserData::AttachToFetcher(url_fetcher.get(), data_use_service_name_);
std::unique_ptr<ImageDataFetcherRequest> request(
new ImageDataFetcherRequest(callback, std::move(url_fetcher)));
« no previous file with comments | « components/data_use_measurement/core/data_use_user_data.cc ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698