Made changes in response to dkowis' comments