Skip to content

Commit

Permalink
Fix #243
Browse files Browse the repository at this point in the history
  • Loading branch information
mganss committed Dec 24, 2020
1 parent f1d0bfa commit 6f55407
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions XmlSchemaClassGenerator/TypeModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ public static IEnumerable<CodeCommentStatement> GetComments(IList<DocumentationM
yield return new CodeCommentStatement("<summary>", true);

foreach (var doc in docs
.Where(d => conf.CommentLanguages.Any(l => d.Language.StartsWith(l, StringComparison.OrdinalIgnoreCase)))
.Where(d => string.IsNullOrEmpty(d.Language) || conf.CommentLanguages.Any(l => d.Language.StartsWith(l, StringComparison.OrdinalIgnoreCase)))
.OrderBy(d => d.Language))
{
var text = doc.Text;
Expand All @@ -86,7 +86,7 @@ public static void AddDescription(CodeAttributeDeclarationCollection attributes,
{
if (!conf.GenerateDescriptionAttribute || DisableComments || !docs.Any()) return;

var doc = GetSingleDoc(docs.Where(d => conf.CommentLanguages.Any(l => d.Language.StartsWith(l, StringComparison.OrdinalIgnoreCase))));
var doc = GetSingleDoc(docs.Where(d => string.IsNullOrEmpty(d.Language) || conf.CommentLanguages.Any(l => d.Language.StartsWith(l, StringComparison.OrdinalIgnoreCase))));

if (doc != null)
{
Expand Down

0 comments on commit 6f55407

Please sign in to comment.