Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/pippy_app.py
diff options
context:
space:
mode:
Diffstat (limited to 'pippy_app.py')
-rw-r--r--pippy_app.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/pippy_app.py b/pippy_app.py
index 54811a3..3be11c6 100644
--- a/pippy_app.py
+++ b/pippy_app.py
@@ -469,15 +469,19 @@ class Chat(ViewSourceActivity):
"""
logger.debug('read_file: reading %s' % file_path)
log = open(file_path).readlines()
+ last_line_was_timestamp = False
for line in log:
if line.endswith('\t\t\n'):
- timestamp = line.strip().split('\t')[0]
- self.add_separator(timestamp)
+ if last_line_was_timestamp is False:
+ timestamp = line.strip().split('\t')[0]
+ self.add_separator(timestamp)
+ last_line_was_timestamp = True
else:
timestamp, nick, color, status, text = line.strip().split('\t')
status_message = bool(int(status))
self.add_text({'nick': nick, 'color': color},
text, status_message)
+ last_line_was_timestamp = False
def _show_via_journal(self, url):
"""Ask the journal to display a URL"""