From 443286aabc9d9e433625e0dd99e678754bbc74e5 Mon Sep 17 00:00:00 2001 From: Anhgelus Morhtuuzh Date: Wed, 25 Feb 2026 16:26:34 +0100 Subject: fix(reducer): double call on startup --- common/timer.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'common/timer.go') diff --git a/common/timer.go b/common/timer.go index 553a8fd..aaea326 100644 --- a/common/timer.go +++ b/common/timer.go @@ -9,8 +9,7 @@ import ( func NewTimer(ctx context.Context, d time.Duration, fn func(context.Context, context.CancelFunc)) context.CancelFunc { ctx, cancel := context.WithCancel(ctx) - logger := bot.Logger(ctx).With("module", "timer") - ctx = bot.SetLogger(ctx, logger) + ctx = bot.SetLogger(ctx, bot.Logger(ctx).With("module", "timer")) go func(ctx context.Context, d time.Duration) { ticker := time.NewTicker(d) fn(ctx, cancel) -- cgit v1.2.3