Skip to content

Commit

Permalink
Caseinsensitive anchor link check (#341)
Browse files Browse the repository at this point in the history
* Caseinsensitive anchor link check

* Also initialize additionalLabels HashSet with StringComparer.OrdinalIgnoreCase
  • Loading branch information
reakaleek authored Jan 24, 2025
1 parent 6f7552d commit d5f8dff
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Elastic.Markdown/IO/MarkdownFile.cs
Original file line number Diff line number Diff line change
Expand Up @@ -60,10 +60,10 @@ public string? NavigationTitle
}

//indexed by slug
private readonly Dictionary<string, PageTocItem> _tableOfContent = new();
private readonly Dictionary<string, PageTocItem> _tableOfContent = new(StringComparer.OrdinalIgnoreCase);
public IReadOnlyDictionary<string, PageTocItem> TableOfContents => _tableOfContent;

private readonly HashSet<string> _additionalLabels = new();
private readonly HashSet<string> _additionalLabels = new(StringComparer.OrdinalIgnoreCase);
public IReadOnlySet<string> AdditionalLabels => _additionalLabels;

public string FilePath { get; }
Expand Down

0 comments on commit d5f8dff

Please sign in to comment.