made the changes based on the comments