Apply micro-optimisation for Nearest API

This commit is contained in:
Siarhei Fedartsou 2024-06-12 18:06:48 +02:00
parent b9df26b3ea
commit dd871e4e3f

View File

@ -112,7 +112,8 @@ class NearestAPI final : public BaseAPI
response.values.emplace("waypoints", std::move(waypoints)); response.values.emplace("waypoints", std::move(waypoints));
} }
response.values.emplace("code", "Ok") auto data_timestamp = facade.GetTimestamp(); response.values.emplace("code", "Ok");
auto data_timestamp = facade.GetTimestamp();
if (!data_timestamp.empty()) if (!data_timestamp.empty())
{ {
response.values.emplace("data_version", data_timestamp); response.values.emplace("data_version", data_timestamp);