From 85dc92a2e7688874ca7aa2e5030be723cd0fc51b Mon Sep 17 00:00:00 2001 From: Yuchen Pei Date: Fri, 16 Sep 2022 10:12:51 +1000 Subject: [server] restoring inline spaces in wikiparser --- src/Servall/WikiParser.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/Servall/WikiParser.hs b/src/Servall/WikiParser.hs index 56f2d94..7aad4ef 100644 --- a/src/Servall/WikiParser.hs +++ b/src/Servall/WikiParser.hs @@ -140,7 +140,7 @@ tempFieldP = do -- parse a field value tempFieldValueP :: Parser Text tempFieldValueP = do - T.concat <$> many' + (T.unwords . T.words . T.concat) <$> many' (choice [ skipRefP , renderInfoTemplate <$> templateP @@ -164,7 +164,7 @@ tempFieldValueP = do <|> (string "") ) ) - if T.null t then fail "simpleP" else return $ T.unwords $ T.words t + if T.null t then fail "simpleP" else return t commentP :: Parser () commentP = do -- cgit v1.2.3