mirror of
https://github.com/spaam/svtplay-dl.git
synced 2024-11-24 04:05:39 +01:00
postprocess.sublanguage.parse: in py3 map return an iterator but we want a list
fixes #444
This commit is contained in:
parent
86c5bd3776
commit
0cb152edef
@ -29,8 +29,8 @@ class postprocess(object):
|
||||
lines = block.strip('-').split('\n')
|
||||
txt = '\r\n'.join(lines[2:])
|
||||
return txt
|
||||
return map(parse_block,
|
||||
open(self).read().strip().replace('\r', '').split('\n\n'))
|
||||
return list(map(parse_block,
|
||||
open(self).read().strip().replace('\r', '').split('\n\n')))
|
||||
|
||||
def query(self):
|
||||
random_sentences = ' '.join(sample(parse(self),8)).replace('\r\n', '')
|
||||
|
Loading…
Reference in New Issue
Block a user