aboutsummaryrefslogtreecommitdiffstats
path: root/includes/OutputTransform
diff options
context:
space:
mode:
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>2024-02-15 20:41:03 +0000
committerGerrit Code Review <gerrit@wikimedia.org>2024-02-15 20:41:03 +0000
commit4d6589dc4a844eb5b69c299dd800a20cfb802a57 (patch)
tree818d8d1afa298e2c3f0348c989c51e9fbb423b8e /includes/OutputTransform
parent2c8f73f334f5bf942d39cd7896367f21ec5d88b4 (diff)
parent87b06ee148832ddddd96506733b7d96de643f217 (diff)
downloadmediawikicore-4d6589dc4a844eb5b69c299dd800a20cfb802a57.tar.gz
mediawikicore-4d6589dc4a844eb5b69c299dd800a20cfb802a57.zip
Merge "HandleSectionLinks: Remove warning when we don't find attributes"
Diffstat (limited to 'includes/OutputTransform')
-rw-r--r--includes/OutputTransform/Stages/HandleSectionLinks.php7
1 files changed, 1 insertions, 6 deletions
diff --git a/includes/OutputTransform/Stages/HandleSectionLinks.php b/includes/OutputTransform/Stages/HandleSectionLinks.php
index de92e3517008..ca683120d42c 100644
--- a/includes/OutputTransform/Stages/HandleSectionLinks.php
+++ b/includes/OutputTransform/Stages/HandleSectionLinks.php
@@ -65,12 +65,7 @@ class HandleSectionLinks extends ContentTextTransformStage {
);
if ( !isset( $attrs['data-mw-anchor'] ) ) {
- if ( str_contains( $m[0], '<span class="mw-headline"' ) ) {
- // Old parser cache entry, already contains replaced headings
- return $m[0];
- }
- // Shouldn't happen, output the node unchanged with a HTML comment to indicate this
- return $m[0] . '<!-- HandleSectionLinks did not find data attributes -->';
+ return $m[0];
}
$anchor = $attrs['data-mw-anchor'];