Fix a few accidental global assignments

Improve global environment hygiene
Merge pull request #4 from pereckerdal/fix-global-assignments

Fix a few accidental global assignments