mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2026-10-12 16:32:10 -05:00
Fix #3253: In Py2 environment, building another locale with a non-captioned toctree produces None captions
This commit is contained in:
1 parent
1ccfb9736b
commit
93dacedfed
2 files changed
+3
-1
No files matched your search
@@ -11,6 +11,8 @@ Bugs fixed
|
|||||||
----------
|
----------
|
||||||
|
|
||||||
* #3246: xapian search adapter crashes
|
* #3246: xapian search adapter crashes
|
||||||
|
* #3253: In Py2 environment, building another locale with a non-captioned
|
||||||
|
toctree produces `None` captions
|
||||||
|
|
||||||
Release 1.5.1 (released Dec 13, 2016)
|
Release 1.5.1 (released Dec 13, 2016)
|
||||||
=====================================
|
=====================================
|
||||||
|
|||||||
+1
-1
@@ -49,7 +49,7 @@ class toctree(nodes.General, nodes.Element, translatable):
|
|||||||
"""Node for inserting a "TOC tree"."""
|
"""Node for inserting a "TOC tree"."""
|
||||||
|
|
||||||
def preserve_original_messages(self):
|
def preserve_original_messages(self):
|
||||||
if 'caption' in self:
|
if self.get('caption'):
|
||||||
self['rawcaption'] = self['caption']
|
self['rawcaption'] = self['caption']
|
||||||
|
|
||||||
def apply_translated_message(self, original_message, translated_message):
|
def apply_translated_message(self, original_message, translated_message):
|
||||||
|
|||||||
Reference in new issue
Block a user