I believe the above modified section could be made better. I'm open to suggestions.