Skip to content

Commit

Permalink
Update some comments about variations headers API use.
Browse files Browse the repository at this point in the history
Based on post-review comments on:
https://codereview.chromium.org/2558913003/

BUG=none
TBR=mattm@chromium.org,donnd@chromium.org,afakhry@chromium.org,noyau@chromium.org

Review-Url: https://codereview.chromium.org/2627033003
Cr-Commit-Position: refs/heads/master@{#443250}
  • Loading branch information
asvitkine-chromium authored and Commit bot committed Jan 12, 2017
1 parent 9265110 commit b2ea4c9
Show file tree
Hide file tree
Showing 9 changed files with 18 additions and 18 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -136,8 +136,8 @@ void ContextualSearchDelegate::ContinueSearchTermResolutionRequest() {

// Add Chrome experiment state to the request headers.
net::HttpRequestHeaders headers;
// Note: It's fine to pass in |is_signed_in| false, which does not affect
// transmission of experiment ids coming from the variations server.
// Note: It's OK to pass |is_signed_in| false if it's unknown, as it does
// not affect transmission of experiments coming from the variations server.
bool is_signed_in = false;
variations::AppendVariationHeaders(
search_term_fetcher_->GetOriginalURL(),
Expand Down
4 changes: 2 additions & 2 deletions chrome/browser/safe_browsing/srt_fetcher_win.cc
Original file line number Diff line number Diff line change
Expand Up @@ -632,8 +632,8 @@ class SRTFetcher : public net::URLFetcherDelegate {
ProfileIOData* io_data = ProfileIOData::FromResourceContext(
profile_->GetResourceContext());
net::HttpRequestHeaders headers;
// Note: It's fine to pass in |is_signed_in| false, which does not affect
// transmission of experiment ids coming from the variations server.
// Note: It's OK to pass |is_signed_in| false if it's unknown, as it does
// not affect transmission of experiments coming from the variations server.
bool is_signed_in = false;
variations::AppendVariationHeaders(
url_fetcher_->GetOriginalURL(), io_data->IsOffTheRecord(),
Expand Down
4 changes: 2 additions & 2 deletions components/autofill/core/browser/autofill_download_manager.cc
Original file line number Diff line number Diff line change
Expand Up @@ -247,8 +247,8 @@ bool AutofillDownloadManager::StartRequest(
net::LOAD_DO_NOT_SEND_COOKIES);
// Add Chrome experiment state to the request headers.
net::HttpRequestHeaders headers;
// Note: It's fine to pass in |is_signed_in| false, which does not affect
// transmission of experiment ids coming from the variations server.
// Note: It's OK to pass |is_signed_in| false if it's unknown, as it does
// not affect transmission of experiments coming from the variations server.
bool is_signed_in = false;
variations::AppendVariationHeaders(fetcher->GetOriginalURL(),
driver_->IsOffTheRecord(), false,
Expand Down
4 changes: 2 additions & 2 deletions components/feedback/feedback_uploader_chrome.cc
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,8 @@ void FeedbackUploaderChrome::DispatchReport(const std::string& data) {
fetcher, data_use_measurement::DataUseUserData::FEEDBACK_UPLOADER);
// Tell feedback server about the variation state of this install.
net::HttpRequestHeaders headers;
// Note: It's fine to pass in |is_signed_in| false, which does not affect
// transmission of experiment ids coming from the variations server.
// Note: It's OK to pass |is_signed_in| false if it's unknown, as it does
// not affect transmission of experiments coming from the variations server.
bool is_signed_in = false;
variations::AppendVariationHeaders(fetcher->GetOriginalURL(),
context_->IsOffTheRecord(), false,
Expand Down
4 changes: 2 additions & 2 deletions components/ntp_snippets/remote/ntp_snippets_json_request.cc
Original file line number Diff line number Diff line change
Expand Up @@ -356,8 +356,8 @@ std::string NTPSnippetsJsonRequest::Builder::BuildHeaders() const {
headers.SetHeader("Authorization", auth_header_);
}
// Add X-Client-Data header with experiment IDs from field trials.
// Note: It's fine to pass in |is_signed_in| false, which does not affect
// transmission of experiment ids coming from the variations server.
// Note: It's OK to pass |is_signed_in| false if it's unknown, as it does
// not affect transmission of experiments coming from the variations server.
bool is_signed_in = false;
variations::AppendVariationHeaders(url_,
false, // incognito
Expand Down
4 changes: 2 additions & 2 deletions components/omnibox/browser/search_provider.cc
Original file line number Diff line number Diff line change
Expand Up @@ -890,8 +890,8 @@ std::unique_ptr<net::URLFetcher> SearchProvider::CreateSuggestFetcher(
fetcher->SetLoadFlags(net::LOAD_DO_NOT_SAVE_COOKIES);
// Add Chrome experiment state to the request headers.
net::HttpRequestHeaders headers;
// Note: It's fine to pass in |is_signed_in| false, which does not affect
// transmission of experiment ids coming from the variations server.
// Note: It's OK to pass |is_signed_in| false if it's unknown, as it does
// not affect transmission of experiments coming from the variations server.
bool is_signed_in = false;
variations::AppendVariationHeaders(fetcher->GetOriginalURL(),
client()->IsOffTheRecord(), false,
Expand Down
4 changes: 2 additions & 2 deletions components/omnibox/browser/zero_suggest_provider.cc
Original file line number Diff line number Diff line change
Expand Up @@ -333,8 +333,8 @@ void ZeroSuggestProvider::Run(const GURL& suggest_url) {
fetcher_->SetLoadFlags(net::LOAD_DO_NOT_SAVE_COOKIES);
// Add Chrome experiment state to the request headers.
net::HttpRequestHeaders headers;
// Note: It's fine to pass in |is_signed_in| false, which does not affect
// transmission of experiment ids coming from the variations server.
// Note: It's OK to pass |is_signed_in| false if it's unknown, as it does
// not affect transmission of experiments coming from the variations server.
bool is_signed_in = false;
variations::AppendVariationHeaders(fetcher_->GetOriginalURL(),
client()->IsOffTheRecord(), false,
Expand Down
4 changes: 2 additions & 2 deletions components/suggestions/suggestions_service_impl.cc
Original file line number Diff line number Diff line change
Expand Up @@ -423,8 +423,8 @@ SuggestionsServiceImpl::CreateSuggestionsRequest(
request->SetRequestContext(url_request_context_);
// Add Chrome experiment state to the request headers.
net::HttpRequestHeaders headers;
// Note: It's fine to pass in |is_signed_in| false, which does not affect
// transmission of experiment ids coming from the variations server.
// Note: It's OK to pass |is_signed_in| false if it's unknown, as it does
// not affect transmission of experiments coming from the variations server.
bool is_signed_in = false;
variations::AppendVariationHeaders(request->GetOriginalURL(), false, false,
is_signed_in, &headers);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -173,8 +173,8 @@ void ContextualSearchDelegate::RequestServerSearchTerm() {

// Add Chrome experiment state to the request headers.
net::HttpRequestHeaders headers;
// Note: It's fine to pass in |is_signed_in| false, which does not affect
// transmission of experiment ids coming from the variations server.
// Note: It's OK to pass |is_signed_in| false if it's unknown, as it does
// not affect transmission of experiments coming from the variations server.
bool is_signed_in = false;
variations::AppendVariationHeaders(search_term_fetcher_->GetOriginalURL(),
browser_state_->IsOffTheRecord(), false,
Expand Down

0 comments on commit b2ea4c9

Please sign in to comment.