mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2026-10-14 01:12:10 -05:00
fix #4214: Two todolist directives break sphinx-1.6.5
This commit is contained in:
1 parent
9158a5be1b
commit
fd94702eed
2 files changed
+3
-1
No files matched your search
@@ -23,6 +23,7 @@ Bugs fixed
|
||||
* #4221: napoleon depends on autodoc, but users need to load it manually
|
||||
* #2298: automodule fails to document a class attribute
|
||||
* #4099: C++: properly link class reference to class from inside constructor
|
||||
* #4214: Two todolist directives break sphinx-1.6.5
|
||||
|
||||
Testing
|
||||
--------
|
||||
|
||||
+2
-1
@@ -178,7 +178,8 @@ def process_todo_nodes(app, doctree, fromdocname):
|
||||
todo_entry = todo_info['todo']
|
||||
# Remove targetref from the (copied) node to avoid emitting a
|
||||
# duplicate label of the original entry when we walk this node.
|
||||
del todo_entry['targetref']
|
||||
if 'targetref' in todo_entry:
|
||||
del todo_entry['targetref']
|
||||
|
||||
# (Recursively) resolve references in the todo content
|
||||
env.resolve_references(todo_entry, todo_info['docname'],
|
||||
|
||||
Reference in new issue
Block a user