Skip to content

Commit

Permalink
Use recursive patterns
Browse files Browse the repository at this point in the history
  • Loading branch information
jnyrup committed Jan 3, 2023
1 parent 1241500 commit afca466
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -13,7 +13,7 @@ internal class MultiDimensionalArrayEquivalencyStep : IEquivalencyStep
{
public EquivalencyResult Handle(Comparands comparands, IEquivalencyValidationContext context, IEquivalencyValidator nestedValidator)
{
if (comparands.Expectation is not Array expectationAsArray || expectationAsArray?.Rank is 1)
if (comparands.Expectation is not Array { Rank: not 1 } expectationAsArray)
{
return EquivalencyResult.ContinueWithNext;
}
Expand Down

0 comments on commit afca466

Please sign in to comment.