Fix #1509 TODO extension not compatible with websupport

websupport assigns UID to every node on reading phase and reads it
on writing phase.
but `todolist` directive generates new paragraph node on resolving phase.
This problem will occur any extensions that generate paragraph nodes
on resolving phase.

This fix changes websupport ignores paragraph node not having UIDs.
This commit is contained in:
tk0miya 2014-08-24 12:28:37 +09:00
parent 38fcb0956f
commit 08cf46cbc9

View File

@ -7,6 +7,7 @@
:license: BSD, see LICENSE for details.
"""
def is_commentable(node):
#return node.__class__.__name__ in ('paragraph', 'literal_block')
return node.__class__.__name__ == 'paragraph'
return node.__class__.__name__ == 'paragraph' and hasattr(node, 'uid')