From e852d12632cd03aa3830d39e05f2d07889f04369 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Maj?= <47927347+michalmaj@users.noreply.github.com> Date: Tue, 6 Feb 2024 17:49:05 +0100 Subject: [PATCH] Update schedule.hpp --- homework/schedule/schedule.hpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/homework/schedule/schedule.hpp b/homework/schedule/schedule.hpp index a1319f3..9c0af70 100644 --- a/homework/schedule/schedule.hpp +++ b/homework/schedule/schedule.hpp @@ -12,9 +12,9 @@ void schedule(T func, std::chrono::seconds duration, Args... args); template void schedule(T func, std::chrono::seconds duration, Args... args) { - auto start = std::chrono::steady_clock::now(); + auto start = std::chrono::steady_clock::now(); - while (std::chrono::steady_clock::now() - start < duration) - ; - std::invoke(func, args...); + while (std::chrono::steady_clock::now() - start < duration) + ; + std::invoke(func, args...); }