Automatically closed - issue fixed for 2 weeks with no activity.
In src/TocBuilder.php, line 45
$dom_node = $dom->getElementById($item['id']);
The result can be null, so the following call
results in an "Error: Call to a member function hasAttributes() on null"
// Get attributes.
$attributes = [];
if ($dom_node->hasAttributes()) {
Drupal text format and filter will filter and process with TOC Filter and the TOC API
And the DOM will empty any h1, h2 ,h3 …
from not allowed internal tags
Then the TOC API will have an empty element which brings the fatal error
e.g.
$dom_node = $dom->getElementById($item['id']);
if (is_null($dom_node)) {
continue;
}
Fixed
1.0
Code
Not all content is available!
It's likely this issue predates Contrib.social: some issue and comment data are missing.
Automatically closed - issue fixed for 2 weeks with no activity.