Ensure branch names in query string are URI encoded