rename config var

This commit is contained in:
naudachu 2023-11-24 14:54:40 +05:00
parent e5feb56360
commit 4c6ed95819
1 changed files with 3 additions and 2 deletions

View File

@ -62,8 +62,9 @@ type ApplicationConfig struct {
// InitConfig
// InitConfig function reads provided file and setup envirmental variables;
func InitConfig(envFilePath string) Config {
err := godotenv.Load(envFilePath)
func InitConfig(env string) Config {
log.Printf("loading ENV from: %s", env)
err := godotenv.Load(env)
if err != nil {
log.Fatal("Error while loading env file")
}