When there are no or multiple level-1 headers parsed, the renderer fails with the following stacktrace:
Unhandled exception: System.InvalidOperationException: Sequence contains no matching element
at System.Linq.ThrowHelper.ThrowNoMatchException()
at System.Linq.Enumerable.Single[TSource](IEnumerable`1 source, Func`2 predicate)
at D2L.Dev.Docs.Render.Program.GetTitle(MarkdownDocument doc) in /render/src/Render/Program.cs:line 91
at D2L.Dev.Docs.Render.Program.DoFile(DocumentContext context, RelativeFile file) in /render/src/Render/Program.cs:line 54
at D2L.Dev.Docs.Render.Program.Main(String input, String output) in /render/src/Render/Program.cs:line 35
Catching this error (or handling it with SingleOrDefault) and outputting a nicer error message would help users understand what's wrong with their docs and fix it themselves.
When there are no or multiple level-1 headers parsed, the renderer fails with the following stacktrace:
Catching this error (or handling it with
SingleOrDefault
) and outputting a nicer error message would help users understand what's wrong with their docs and fix it themselves.Related issue: #9