From e8921bbbfe142c4c1d9b7cebfd6230046ac06858 Mon Sep 17 00:00:00 2001 From: Domenic Denicola Date: Thu, 22 Oct 2020 22:39:47 -0400 Subject: [PATCH] Fix more cases of extra spaces after periods --- lib/convert-worker.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/convert-worker.js b/lib/convert-worker.js index db0d832..1a1e64d 100644 --- a/lib/convert-worker.js +++ b/lib/convert-worker.js @@ -135,7 +135,7 @@ function getBodyXML(chapter, contentEl) { // If they show up three in a row, then let them live. Otherwise, they die. // Also remove any run of them after a period. xml = xml.replace(/([^\xA0])\xA0\xA0?([^\xA0])/g, "$1 $2"); - xml = xml.replace(/\.\xA0+\s*/, ". "); + xml = xml.replace(/\.\x20*\xA0[\xA0\x20]*/, ". "); function fixEms() { // Fix recurring broken-up or erroneous s