From 8d9cd6c880afd4b31f353e08ba1f81ac84114f9e Mon Sep 17 00:00:00 2001 From: Alexander Morozov Date: Wed, 4 Oct 2017 14:24:19 -0700 Subject: [PATCH] Replace NewTimer().C with After It is the same thing Signed-off-by: Alexander Morozov Upstream-commit: 1a517a4a429d2b4db15383fc9d514fc8db66f8d3 Component: engine --- components/engine/api/server/router/system/system_routes.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/engine/api/server/router/system/system_routes.go b/components/engine/api/server/router/system/system_routes.go index 62060a4ccf..8f6aecd77a 100644 --- a/components/engine/api/server/router/system/system_routes.go +++ b/components/engine/api/server/router/system/system_routes.go @@ -123,7 +123,7 @@ func (s *systemRouter) getEvents(ctx context.Context, w http.ResponseWriter, r * if !onlyPastEvents { dur := until.Sub(now) - timeout = time.NewTimer(dur).C + timeout = time.After(dur) } }