From c38e46fc2af93037f8e6ebe5925569f42753de47 Mon Sep 17 00:00:00 2001 From: Tulir Asokan Date: Fri, 28 Sep 2018 17:15:57 +0300 Subject: [PATCH] Fix linebreaks in pre blocks --- mautrix_telegram/formatter/from_matrix/parser_lxml.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mautrix_telegram/formatter/from_matrix/parser_lxml.py b/mautrix_telegram/formatter/from_matrix/parser_lxml.py index 424495cc..9fa99982 100644 --- a/mautrix_telegram/formatter/from_matrix/parser_lxml.py +++ b/mautrix_telegram/formatter/from_matrix/parser_lxml.py @@ -52,7 +52,7 @@ class RecursionContext: return RecursionContext(strip_linebreaks=self.strip_linebreaks, ul_depth=self.ul_depth + 1) def enter_code_block(self) -> 'RecursionContext': - return RecursionContext(strip_linebreaks=True, ul_depth=self.ul_depth) + return RecursionContext(strip_linebreaks=False, ul_depth=self.ul_depth) class MatrixParser(MatrixParserCommon):