comments and code clean up