Skip to content
Snippets Groups Projects
Commit 3ee0b0b7 authored by catch's avatar catch
Browse files

Issue #3238457 by alexpott, paulocs: Fix...

Issue #3238457 by alexpott, paulocs: Fix \Drupal\Core\EventSubscriber\ActiveLinkResponseFilter::setLinkActiveClass() to not trigger a deprecation on PHP 8.1
parent c6c5559a
No related branches found
No related tags found
Loading
......@@ -181,7 +181,7 @@ public static function setLinkActiveClass($html_markup, $current_path, $is_front
// Get the HTML: this will be the opening part of a single tag, e.g.:
// <a href="/" data-drupal-link-system-path="&lt;front&gt;">
$tag = substr($html_markup, $pos_tag_start, $pos_tag_end - $pos_tag_start + 1);
$tag = substr($html_markup, $pos_tag_start ?? 0, $pos_tag_end - $pos_tag_start + 1);
// Parse it into a DOMDocument so we can reliably read and modify
// attributes.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment