From 9bc2bfca0472f0d95e136f85eacef1ef632600a7 Mon Sep 17 00:00:00 2001 From: ROuGGy Date: Sun, 17 Dec 2023 21:08:55 +0700 Subject: [PATCH] t --- DeleteArr.go | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/DeleteArr.go b/DeleteArr.go index 6ab5d68..9989cb2 100644 --- a/DeleteArr.go +++ b/DeleteArr.go @@ -59,6 +59,11 @@ func main() { // os.Setenv("radarr_eventtype", "Download") // os.Setenv("EventType", "Test") + if os.Getenv("EventType") == "Test" { + log.Println("Radarr/Sonarr is testing the script and it works") + os.Exit(0) + } + ex, err := os.Executable() if err != nil { panic(err) @@ -76,11 +81,6 @@ func main() { RadarrEventType := os.Getenv("radarr_eventtype") SonarrEventType := os.Getenv("sonarr_eventtype") - if os.Getenv("EventType") == "Test" { - log.Println("Radarr/Sonarr is testing the script and it works") - os.Exit(1) - } - m := &MediaFiles{} if RadarrEventType != "" {