Goose\Modules\Formatters\OutputFormatter::cleanupHtml PHP Method

cleanupHtml() private method

Scrape the node content and return the html
private cleanupHtml ( ) : string
return string Formatted string with all HTML
    private function cleanupHtml()
    {
        $topNode = $this->article()->getTopNode();
        if (empty($topNode)) {
            return '';
        }
        $this->removeParagraphsWithFewWords($topNode);
        $html = $this->convertToHtml($topNode);
        return str_replace(['<p></p>', '<p>&nbsp;</p>'], '', $html);
    }