Implemented some minor suggestions from Ty Smith