Skip to content
This repository was archived by the owner on Dec 24, 2022. It is now read-only.

Commit 8dcc5be

Browse files
committed
remove non-PCL compatible GetRedirectUrlIfAny
1 parent 7f1222c commit 8dcc5be

File tree

1 file changed

+0
-14
lines changed

1 file changed

+0
-14
lines changed

src/ServiceStack.Text/HttpUtils.cs

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -756,20 +756,6 @@ public static string PutXmlToUrl(this string url, object data,
756756
requestFilter: requestFilter, responseFilter: responseFilter);
757757
}
758758
#endif
759-
760-
public static string GetRedirectUrlIfAny(this string url)
761-
{
762-
var finalUrl = url;
763-
try
764-
{
765-
var ignore = url.GetBytesFromUrl(
766-
requestFilter: req => { req.AllowAutoRedirect = false; req.UserAgent = UserAgent; },
767-
responseFilter: res => finalUrl = res.Headers[HttpHeaders.Location] ?? finalUrl);
768-
}
769-
catch { }
770-
771-
return finalUrl;
772-
}
773759
}
774760

775761
public interface IHttpResultsFilter : IDisposable

0 commit comments

Comments
 (0)