Fix missing spaces at <br/> elements
diff --git a/test/test-xml.sh b/test/test-xml.sh
index f2a85ac..c50bab9 100755
--- a/test/test-xml.sh
+++ b/test/test-xml.sh
@@ -53,6 +53,14 @@
((ERRORS++))
fi
+observed=$(grep -Ec '^Copyright' target/dnb13.i5.xml)
+if $(assert_eq "$observed" "2"); then
+ log_success "spaces at <br> elements are inserted correctly"
+else
+ log_failure "spaces at <br> elements are not inserted correctly"
+ ((ERRORS++))
+fi
+
if [ $ERRORS -gt 0 ]; then
log_failure "There were $ERRORS errors"
diff --git a/xslt/epub2i5.xsl b/xslt/epub2i5.xsl
index d87530f..82a18d3 100644
--- a/xslt/epub2i5.xsl
+++ b/xslt/epub2i5.xsl
@@ -509,7 +509,9 @@
</xsl:if>
</xsl:template>
- <xsl:template match="xhtml:br"/>
+ <xsl:template match="xhtml:br">
+ <lb/><xsl:text> </xsl:text>
+ </xsl:template>
<xsl:template match="xhtml:*">
<xsl:message>