comments and some cleanup