Fixed #19693 -- Made truncatewords_html handle self-closing tags

Thanks sneawo for the report and Jonathan Loy for the patch.