We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 16cbcb8 commit 81cd18aCopy full SHA for 81cd18a
1 file changed
src/sphinxnotes/data/render/datanodes.py
@@ -163,10 +163,8 @@ def replace_self_inline(
163
ns, msgs = rendered.inline(inliner)
164
165
# Insert reports to nearst block elements (usually nodes.paragraph).
166
- blkparent = find_nearest_block_element(self.parent) or find_current_document(
167
- self
168
- )
169
- assert blkparent
+ doctree = inliner.document if isinstance(inliner, Inliner) else inliner[1]
+ blkparent = find_nearest_block_element(self.parent) or doctree
170
blkparent += msgs
171
172
# Replace self with inline nodes.
0 commit comments