Removed the use of the environ variable and instead use the environment array