Code comments and tidy