diff --git a/src/Microsoft.AspNetCore.Mvc.Core/ApiExplorer/ApiConventionMatcher.cs b/src/Microsoft.AspNetCore.Mvc.Core/ApiExplorer/ApiConventionMatcher.cs index b9e6f593c3..e080ce4ef4 100644 --- a/src/Microsoft.AspNetCore.Mvc.Core/ApiExplorer/ApiConventionMatcher.cs +++ b/src/Microsoft.AspNetCore.Mvc.Core/ApiExplorer/ApiConventionMatcher.cs @@ -15,12 +15,7 @@ namespace Microsoft.AspNetCore.Mvc.ApiExplorer bool MethodMatches() { var methodNameMatchBehavior = GetNameMatchBehavior(conventionMethod); - if (!IsNameMatch(methodInfo.Name, conventionMethod.Name, methodNameMatchBehavior)) - { - return false; - } - - return true; + return IsNameMatch(methodInfo.Name, conventionMethod.Name, methodNameMatchBehavior); } bool ParametersMatch()