Skip to content

Commit

Permalink
Fix bug with "System.MissingMethodException"
Browse files Browse the repository at this point in the history
  • Loading branch information
unchase committed Mar 25, 2020
1 parent 18c8159 commit d9bca60
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 8 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@

These are the changes to each version that has been released on the [nuget](https://www.nuget.org/packages/Unchase.Swashbuckle.AspNetCore.Extensions/).

## v2.3.1 `(2020-03-25)`

- [x] Fix bug with `System.MissingMethodException`

## v2.3.0 `(2020-03-23)`

- [x] Add feature: add configured options to `AddEnumsWithValuesFixFilters`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,12 +50,19 @@ private static string TryGetMemberComments(MemberInfo memberInfo, IEnumerable<XP
if (xmlNavigators == null)
return string.Empty;

foreach (var xmlNavigator in xmlNavigators)
try
{
var xpathNavigator1 = xmlNavigator.SelectSingleNode(
$"/doc/members/member[@name='{XmlCommentsNodeNameHelper.GetNodeNameForMember(memberInfo)}']");
var xpathNavigator2 = xpathNavigator1?.SelectSingleNode("summary");
return xpathNavigator2 != null ? XmlCommentsTextHelper.Humanize(xpathNavigator2.InnerXml) : string.Empty;
foreach (var xmlNavigator in xmlNavigators)
{
var xpathNavigator1 = xmlNavigator.SelectSingleNode(
$"/doc/members/member[@name='{XmlCommentsNodeNameHelper.GetNodeNameForMember(memberInfo)}']");
var xpathNavigator2 = xpathNavigator1?.SelectSingleNode("summary");
return xpathNavigator2 != null ? XmlCommentsTextHelper.Humanize(xpathNavigator2.InnerXml) : string.Empty;
}
}
catch
{
return string.Empty;
}

return string.Empty;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@
<NeutralLanguage></NeutralLanguage>
<LangVersion>7.3</LangVersion>
<PackageIconUrl>https://github.com/unchase/Unchase.Swashbuckle.AspNetCore.Extensions/blob/master/assets/icon.png?raw=true</PackageIconUrl>
<Version>2.3.0</Version>
<AssemblyVersion>2.3.0.0</AssemblyVersion>
<FileVersion>2.3.0.0</FileVersion>
<Version>2.3.1</Version>
<AssemblyVersion>2.3.1.0</AssemblyVersion>
<FileVersion>2.3.1.0</FileVersion>
<GeneratePackageOnBuild>false</GeneratePackageOnBuild>
<DocumentationFile>Unchase.Swashbuckle.AspNetCore.Extensions.xml</DocumentationFile>
</PropertyGroup>
Expand Down

0 comments on commit d9bca60

Please sign in to comment.