Created
August 16, 2021 14:38
-
-
Save zdi-team/1b1ae9638aa05bcee06793169cf60ecf to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static string RemoveExplicitLogonFromUrlAbsoluteUri(string absoluteUri, string explicitLogonAddress) { | |
ArgumentValidator.ThrowIfNull("absoluteUri", absoluteUri); | |
ArgumentValidator.ThrowIfNull("explicitLogonAddress", explicitLogonAddress); | |
string text = "/" + explicitLogonAddress; | |
int num = absoluteUri.IndexOf(text); | |
if (num != -1) { | |
return absoluteUri.Substring(0, num) + absoluteUri.Substring(num + text.Length); | |
} | |
return absoluteUri; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment