Make q parameter less prone to building invalid URLs with duplicate tags and spaces