Don't apply multiplier twice
This commit is contained in:
parent
28ee194297
commit
092b925a25
1 changed files with 0 additions and 1 deletions
|
@ -179,7 +179,6 @@ func (as *alerter) eval(ctx context.Context, now time.Time, testMode bool) ([]Al
|
||||||
|
|
||||||
if s.Score > as.cfg.AlertThreshold || testMode {
|
if s.Score > as.cfg.AlertThreshold || testMode {
|
||||||
if old, inCache := as.alertCache[s.ID]; !inCache || now.Sub(old.Timestamp) > as.renotify {
|
if old, inCache := as.alertCache[s.ID]; !inCache || now.Sub(old.Timestamp) > as.renotify {
|
||||||
s.Score *= as.tgCache.ApplyAlertRules(s.ID, now)
|
|
||||||
a, err := as.makeAlert(ctx, s, origScore)
|
a, err := as.makeAlert(ctx, s, origScore)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, fmt.Errorf("makeAlert: %w", err)
|
return nil, fmt.Errorf("makeAlert: %w", err)
|
||||||
|
|
Loading…
Reference in a new issue