fixes trailing spaces in hrefs when used for tooltips