Skip to content

Commit e04bb75

Browse files
Update StringExtensions.cs
1 parent 0ea0535 commit e04bb75

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/WouterVanRanst.Utils/Extensions/StringExtensions.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ public static string Left(this string str, int length)
1414
return str[..Math.Min(str.Length, length)];
1515
}
1616

17-
public static string RemovePrefix(this string s, string prefix)
17+
public static string RemovePrefix(this string s, string prefix, StringComparison comparisonType = StringComparison.InvariantCultureIgnoreCase)
1818
{
19-
if (s.StartsWith(prefix))
19+
if (s.StartsWith(prefix, comparisonType))
2020
return s[prefix.Length..];
2121

2222
return s;

0 commit comments

Comments
 (0)