Use a closure
Remove commented out code
Minor whitespace cleanup