Skip to content
Browse files

Avoid error in doctrinedownloads.py when stability is not specified.

  • Loading branch information...
1 parent 0420a75 commit 6fca436aad453eb8e0ced0bae948b14f1c32ff18 @jwage jwage committed Jan 13, 2013
Showing with 6 additions and 1 deletion.
  1. +6 −1 pages/source/_exts/doctrinedownloads.py
View
7 pages/source/_exts/doctrinedownloads.py
@@ -78,7 +78,12 @@ def visit_doctrinedownloads_html(self, node):
self.body.append(self.starttag(node, 'div', CLASS='version'))
versiondata = node['project']['versions'][version];
- self.body.append('<h3>Download %s (%s)</h3>' % ( version, versiondata['stability'] ))
+ if 'stability' in versiondata:
+ stability = versiondata['stability']
+ else:
+ stability = 'alpha'
+
+ self.body.append('<h3>Download %s (%s)</h3>' % ( version, stability ))
self.body.append('<ul class="release">');
self.body.append('<li><a href="/docs/%s/%s/en/index.html">Documentation (%s)</a></li>' % (node['project']['slug'], version, version))

0 comments on commit 6fca436

Please sign in to comment.
Something went wrong with that request. Please try again.