Cleaning up and commenting code for code review