From 31e8e924e86330ffa9bc023de4af38664e5b27f0 Mon Sep 17 00:00:00 2001 From: nikk gitanes Date: Sun, 19 Feb 2023 21:38:18 +0300 Subject: [PATCH] temp timer test --- server/torr/torrent.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/server/torr/torrent.go b/server/torr/torrent.go index 7be01c4..e6d783c 100644 --- a/server/torr/torrent.go +++ b/server/torr/torrent.go @@ -135,13 +135,14 @@ func (t *Torrent) AddExpiredTime(duration time.Duration) { } func (t *Torrent) watch() { - t.progressTicker = time.NewTicker(time.Second) + t.progressTicker = time.NewTicker(time.Second / 2) defer t.progressTicker.Stop() for { select { case <-t.progressTicker.C: go t.progressEvent() + time.Sleep(time.Second / 2) // FIXME! TEMP TEST TIMER case <-t.closed: return }