Commit 11bae6b7 authored by Max Morin's avatar Max Morin Committed by Commit Bot

Filter studies by OS version.

An earlier CL added the function to filter studies by OS version, but
didn't actually call it. This CL calls the function and was manually
verified to work (with a local instance of the variations server).

Bug: 956059
Change-Id: I7f5af7a0f846ebe5c1cc5734922b5391725d9255
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1609853
Commit-Queue: Max Morin <maxmorin@chromium.org>
Commit-Queue: Alexei Svitkine <asvitkine@chromium.org>
Auto-Submit: Max Morin <maxmorin@chromium.org>
Reviewed-by: default avatarAlexei Svitkine <asvitkine@chromium.org>
Cr-Commit-Position: refs/heads/master@{#659942}
parent f0c6e2ad
......@@ -274,6 +274,12 @@ bool ShouldAddStudy(const Study& study,
return false;
}
if (!CheckStudyOSVersion(study.filter(), client_state.os_version)) {
DVLOG(1) << "Filtered out study " << study.name()
<< " due to os_version.";
return false;
}
const std::string& country = GetClientCountryForStudy(study, client_state);
if (!CheckStudyCountry(study.filter(), country)) {
DVLOG(1) << "Filtered out study " << study.name() << " due to country.";
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment