Code review

Addressing the suggestions made in my last code review.