From 3a68da81e1b82dfa14e000a0a7333f5b78e99baf Mon Sep 17 00:00:00 2001 From: Pavel Date: Sun, 3 Mar 2024 21:26:46 +0300 Subject: [PATCH] change promo history --- internal/repository/promocode_stats.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/repository/promocode_stats.go b/internal/repository/promocode_stats.go index c439549..1daf023 100644 --- a/internal/repository/promocode_stats.go +++ b/internal/repository/promocode_stats.go @@ -26,7 +26,7 @@ func (r *StatsRepository) UpdateStatistics(ctx context.Context, req *models.Acti return err } - if count == 1 { + if count >= 1 { return ErrPromoCodeAlreadyActivated }