diff --git a/map/search_api.cpp b/map/search_api.cpp index ffed34da59..ed2ea1924c 100644 --- a/map/search_api.cpp +++ b/map/search_api.cpp @@ -20,9 +20,7 @@ #include "geometry/mercator.hpp" #include "base/checked_cast.hpp" -#include "base/scope_guard.hpp" #include "base/string_utils.hpp" -#include "base/timer.hpp" #include #include @@ -206,11 +204,6 @@ bool SearchAPI::SearchEverywhere(EverywhereSearchParams const & params) m_delegate.OnBookingFilterParamsUpdate(params.m_bookingFilterTasks); - LOG(LINFO, ("Search everywhere started.")); - base::Timer timer; - SCOPE_GUARD(printDuration, [&timer]() { - LOG(LINFO, ("Search everywhere ended. Time:", timer.ElapsedSeconds(), "seconds.")); - }); return Search(p, true /* forceSearch */); } diff --git a/search/engine.cpp b/search/engine.cpp index 996af5cf2d..89a8077ec3 100644 --- a/search/engine.cpp +++ b/search/engine.cpp @@ -9,6 +9,7 @@ #include "base/scope_guard.hpp" #include "base/stl_helpers.hpp" +#include "base/timer.hpp" #include #include @@ -282,6 +283,12 @@ void Engine::PostMessage(Args &&... args) void Engine::DoSearch(SearchParams const & params, shared_ptr handle, Processor & processor) { + LOG(LINFO, ("Search started.")); + base::Timer timer; + SCOPE_GUARD(printDuration, [&timer]() { + LOG(LINFO, ("Search ended. Time:", timer.ElapsedSeconds(), "seconds.")); + }); + processor.Reset(); handle->Attach(processor); SCOPE_GUARD(detach, [&handle] { handle->Detach(); });