Minor changes, clearing unused variables from global namespace