The following line in your config.Config () function will be called each time you try to get property from the os.GetEnv.
err := godotenv.Load(".env")
This is bad practice to read and load the file each time you need to find a configuration. Overkill. You should read your property file once at the start of main().
The following line in your config.Config () function will be called each time you try to get property from the os.GetEnv.
err := godotenv.Load(".env")This is bad practice to read and load the file each time you need to find a configuration. Overkill. You should read your property file once at the start of main().