Refactor the way the environment is stored

* Save a boolean for Node.js or not, rather than a string
* Use more english-y style when choosing between the two