Example #1
0
        private static string BuildFinalUrl(this HttpClient httpClient, string url, QueryString queryString = null)
        {
            var finalUrl = UrlUtility.Combine(httpClient.BaseAddress.OriginalString, url);

            if (queryString == null)
            {
                return(finalUrl.ToString());
            }
            finalUrl = UrlUtility.AppendQueryString(finalUrl, queryString.ToString());

            return(finalUrl);
        }