TIL splitlines()

This commit is contained in:
Florent Le Coz 2013-09-06 17:35:50 +02:00
parent 2f6324571e
commit 099d1d1c2c

View file

@ -131,7 +131,7 @@ class Logger(object):
if pos == -1: # If we don't have enough lines in the file if pos == -1: # If we don't have enough lines in the file
pos = 1 # 1, because we do -1 just on the next line pos = 1 # 1, because we do -1 just on the next line
# to get 0 (start of the file) # to get 0 (start of the file)
lines = m[pos-1:].decode(errors='replace').split("\n")[:-1] lines = m[pos-1:].decode(errors='replace').splitlines()
messages = [] messages = []
color = '\x19%s}' % dump_tuple(get_theme().COLOR_INFORMATION_TEXT) color = '\x19%s}' % dump_tuple(get_theme().COLOR_INFORMATION_TEXT)