From 917d6d9103f1ed97e54dccdba91fc9db9a71a6d2 Mon Sep 17 00:00:00 2001 From: stuzer05 Date: Tue, 8 Oct 2024 16:58:13 +0300 Subject: [PATCH] Remove load .env from bin path --- main.go | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/main.go b/main.go index 7122272..a2e9db0 100644 --- a/main.go +++ b/main.go @@ -12,20 +12,12 @@ import ( "log" "net/http" "os" - "path/filepath" "stuzer.link/monobank-firefly3-bot/app" ) func main() { - // Get executable directory - exePath, err := os.Executable() - if err != nil { - log.Fatal("Error getting executable path:", err) - } - exeDir := filepath.Dir(exePath) - // load .env - godotenv.Load(filepath.Join(exeDir, ".env")) + godotenv.Load(".env") // init app app.Init()