Поправки

This commit is contained in:
Book Pauk
2019-01-26 23:52:48 +07:00
parent 54b4b4795b
commit d0511e8b86

View File

@@ -293,7 +293,7 @@ class BookConverter {
openTag('strong'); openTag('strong');
break; break;
case 'div': case 'div':
if (tail == 'center') { if (tail.indexOf('align="center"') >= 0) {
openTag('subtitle'); openTag('subtitle');
inSubtitle = true; inSubtitle = true;
} }
@@ -326,7 +326,9 @@ class BookConverter {
closeTag('strong'); closeTag('strong');
break; break;
case 'div': case 'div':
closeTag('subtitle'); if (inSubtitle)
closeTag('subtitle');
inSubtitle = false;
break; break;
} }
} }