Regression due to previous patch

Fixing installer regression due to patch #1972
Merge pull request #1989 from dhensby/patch-environment-regression

Regression due to previous patch