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

Commit a0c45fb

Browse files
committed
move optional ContainsAny param to end
1 parent 4eb4c35 commit a0c45fb

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/ServiceStack.Text/StringExtensions.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -918,7 +918,7 @@ public static bool ContainsAny(this string text, params string[] testMatches)
918918
return false;
919919
}
920920

921-
public static bool ContainsAny(this string text, StringComparison comparisonType, params string[] testMatches)
921+
public static bool ContainsAny(this string text, string[] testMatches, StringComparison comparisonType)
922922
{
923923
foreach (var testMatch in testMatches)
924924
{

tests/ServiceStack.Text.Tests/StringExtensionsTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -351,7 +351,7 @@ public void Does_ContainsAny_Return_CaseInsensitive_Matches()
351351
var testMatches = new string[] { "abc" };
352352
var input = "ABC";
353353

354-
Assert.That(input.ContainsAny(StringComparison.OrdinalIgnoreCase, testMatches));
354+
Assert.That(input.ContainsAny(testMatches, StringComparison.OrdinalIgnoreCase));
355355
}
356356
}
357357
}

0 commit comments

Comments
 (0)