aboutsummaryrefslogtreecommitdiffstats
path: root/libbe/command/html.py
diff options
context:
space:
mode:
Diffstat (limited to 'libbe/command/html.py')
-rw-r--r--libbe/command/html.py22
1 files changed, 6 insertions, 16 deletions
diff --git a/libbe/command/html.py b/libbe/command/html.py
index ed43808..5ec8691 100644
--- a/libbe/command/html.py
+++ b/libbe/command/html.py
@@ -100,21 +100,11 @@ class ServerApp (libbe.util.wsgi.WSGI_AppObject,
self.logger.log(
self.log_level, 'generate {} index file for {} bugs'.format(
bug_type, len(bugs)))
- template_info = {
- 'title': self.title,
- 'charset': 'UTF-8',
- 'stylesheet': 'style.css',
- 'header': self.header,
- 'active_class': 'tab nsel',
- 'inactive_class': 'tab nsel',
- 'target_class': 'tab nsel',
- 'bugs': bugs,
- 'bug_entry': self.template.get_template('index_bug_entry.html'),
- 'bug_dir': self.bug_dir,
- 'index_file': self._index_file,
- 'generation_time': self._generation_time(),
- }
- template_info['{}_class'.format(bug_type)] = 'tab sel'
+ template_info = {'title': self.title, 'charset': 'UTF-8', 'stylesheet': 'style.css', 'header': self.header,
+ 'active_class': 'tab nsel', 'inactive_class': 'tab nsel', 'target_class': 'tab nsel',
+ 'bugs': bugs, 'bug_entry': self.template.get_template('index_bug_entry.html'),
+ 'bug_dir': self.bug_dir, 'index_file': self._index_file,
+ 'generation_time': self._generation_time(), '{}_class'.format(bug_type): 'tab sel'}
if bug_type == 'target':
template = self.template.get_template('target_index.html')
template_info['targets'] = [
@@ -314,7 +304,7 @@ class ServerApp (libbe.util.wsgi.WSGI_AppObject,
return time.ctime()
def _escape(self, string):
- if string == None:
+ if string is None:
return ''
return xml.sax.saxutils.escape(string)