Fixed issue #7 with closure scope.