Refactor and simplify.
Remove commented code.