Clean up and commented code.