add comment and clean up