Fix typo and missing env var