qpLinkToSpan is supposed to return a string representing the html page being processed. However, if your HTML page has no anchor elements (unrealistic in the real world, but my testing file for import has only text) qpLinkToSpan returns FALSE. It should instead return the original content.
Context in which qpLinkToSpan is called. Notice assigning return value to mContent
$this->mContent = self::qpLinkToSpan($this->mContent);
Current master version:
public static function qpLinkToSpan($content) {
$qp = htmlqp($content, 'a');
if ( $qp->length == 0 ) {
return $content;
}My Modified Version:
public static function qpLinkToSpan($content) {
$qp = htmlqp($content, 'a');
if ( $qp->length == 0 ) {
// return false;
return $content;
}