Adding var to prevent variables from leaking into global scope.