fix ugly string building