diff options
author | Tim Graham <timograham@gmail.com> | 2014-06-06 20:31:23 -0400 |
---|---|---|
committer | Tim Graham <timograham@gmail.com> | 2014-06-06 20:31:23 -0400 |
commit | 7f4347b1766b34d4c970226ca1be539d78b3d8b5 (patch) | |
tree | c82d5909410936ff7471f7d743b624f0431a315d /docs/_ext/djangodocs.py | |
parent | 5472bf4df079bec171db4e8a62659e9782595ce2 (diff) | |
download | django-7f4347b1766b34d4c970226ca1be539d78b3d8b5.tar.gz |
Removed duplicate "Deprecated in Django A.B" text in docs.
sphinx 1.2+ adds this text itself.
Diffstat (limited to 'docs/_ext/djangodocs.py')
-rw-r--r-- | docs/_ext/djangodocs.py | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/docs/_ext/djangodocs.py b/docs/_ext/djangodocs.py index 0a134e775f..6770ff46ac 100644 --- a/docs/_ext/djangodocs.py +++ b/docs/_ext/djangodocs.py @@ -269,7 +269,6 @@ class DjangoHTMLTranslator(SmartyPantsHTMLTranslator): # that work. # version_text = { - 'deprecated': 'Deprecated in Django %s', 'versionchanged': 'Changed in Django %s', 'versionadded': 'New in Django %s', } @@ -278,11 +277,13 @@ class DjangoHTMLTranslator(SmartyPantsHTMLTranslator): self.body.append( self.starttag(node, 'div', CLASS=node['type']) ) - title = "%s%s" % ( - self.version_text[node['type']] % node['version'], - ":" if len(node) else "." - ) - self.body.append('<span class="title">%s</span> ' % title) + version_text = self.version_text.get(node['type']) + if version_text: + title = "%s%s" % ( + version_text % node['version'], + ":" if len(node) else "." + ) + self.body.append('<span class="title">%s</span> ' % title) def depart_versionmodified(self, node): self.body.append("</div>\n") |