changed string params to const ref