bug fix for badge links

fixes issue with extra text getting added to end of some badge links.