Skip to content

Commit

Permalink
chore: use ToArray over ToList
Browse files Browse the repository at this point in the history
  • Loading branch information
TimothyMakkison committed Dec 8, 2023
1 parent 52b310a commit 8a4d978
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Refit/RequestBuilderImplementation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -132,9 +132,9 @@ RestMethodInfoInternal FindMatchingRestMethodInfo(
method => !method.MethodInfo.IsGenericMethod
);

var possibleMethods = possibleMethodsList.ToList();
var possibleMethods = possibleMethodsList.ToArray();

if (possibleMethods.Count == 1)
if (possibleMethods.Length == 1)
return CloseGenericMethodIfNeeded(possibleMethods[0], genericArgumentTypes);

foreach (var method in possibleMethods)
Expand Down

0 comments on commit 8a4d978

Please sign in to comment.