mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-12-28 11:21:12 +08:00
[vcpkg] fix feature flags telemetry (#14856)
* [vcpkg] fix feature flags telemetry * change to robert's suggestion
This commit is contained in:
parent
7313144886
commit
a1d48dc8ec
@ -155,8 +155,6 @@ namespace vcpkg::Metrics
|
||||
Json::Array buildtime_names;
|
||||
Json::Array buildtime_times;
|
||||
|
||||
Json::Object feature_flags;
|
||||
|
||||
void track_property(const std::string& name, const std::string& value)
|
||||
{
|
||||
properties.insert_or_replace(name, Json::Value::string(value));
|
||||
@ -174,7 +172,7 @@ namespace vcpkg::Metrics
|
||||
}
|
||||
void track_feature(const std::string& name, bool value)
|
||||
{
|
||||
feature_flags.insert(name, Json::Value::boolean(value));
|
||||
properties.insert("feature-flag-" + name, Json::Value::boolean(value));
|
||||
}
|
||||
|
||||
std::string format_event_data_template() const
|
||||
@ -234,7 +232,6 @@ namespace vcpkg::Metrics
|
||||
base_data.insert("name", Json::Value::string("commandline_test7"));
|
||||
base_data.insert("properties", std::move(props_plus_buildtimes));
|
||||
base_data.insert("measurements", measurements);
|
||||
base_data.insert("feature-flags", feature_flags);
|
||||
}
|
||||
|
||||
return Json::stringify(arr, vcpkg::Json::JsonStyle());
|
||||
|
Loading…
x
Reference in New Issue
Block a user