From 8fa7736b88525389cb019302f74f42087bcea0d9 Mon Sep 17 00:00:00 2001 From: Matthieu 'JP' DERASSE Date: Wed, 21 Jun 2023 13:47:10 +0000 Subject: [PATCH] feat(demo): Do not alert for demo --- alert/alert.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/alert/alert.go b/alert/alert.go index d27519f..6d54d67 100644 --- a/alert/alert.go +++ b/alert/alert.go @@ -67,6 +67,11 @@ func checkPrice(alertChan chan api.Availability) { } for _, availability := range availabilities.Results { + + if availability.IsDemo { + continue + } + if availability.Price < 39000 && availability.Trim[0] == "SRRWD" { log.Info("Launching an alert !") alertChan <- availability