Fix bug with env variables