mirror of
https://github.com/xoofx/markdig.git
synced 2026-11-16 09:20:40 +00:00
Added error throwing when stack is empty and PopIndent() is called
This commit is contained in:
@@ -176,6 +176,8 @@ public abstract class TextRendererBase<T> : TextRendererBase where T : TextRende
|
||||
{
|
||||
if (this.indents.Count > 0)
|
||||
indents.RemoveAt(indents.Count - 1);
|
||||
else
|
||||
throw new InvalidOperationException("No indent to pop");
|
||||
}
|
||||
|
||||
public void ClearIndent() => indents.Clear();
|
||||
|
||||
Reference in New Issue
Block a user