From 47172479bb2cafbdbede2b0636d83e30e33b2c89 Mon Sep 17 00:00:00 2001 From: Reedy Date: Tue, 22 Aug 2023 20:46:36 +0000 Subject: [PATCH] ExtractFormatter: Update for HtmlFormatter 4.0.0 Bug: T330528 Depends-On: Id785cfd2e00762ca6c1ea80200dd4a3d197640f2 Change-Id: I496d84fab3ee8feee5891ca984f37e90837d857c --- includes/ExtractFormatter.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/includes/ExtractFormatter.php b/includes/ExtractFormatter.php index ce2de51..1cde6f7 100644 --- a/includes/ExtractFormatter.php +++ b/includes/ExtractFormatter.php @@ -44,7 +44,7 @@ class ExtractFormatter extends HtmlFormatter { * Ignored * @return string Processed HTML */ - public function getText( $element = null ) { + public function getText( $element = null ): string { $this->filterContent(); $text = parent::getText(); if ( $this->plainText ) { @@ -63,7 +63,7 @@ class ExtractFormatter extends HtmlFormatter { * @param string $html HTML string to process * @return string Processed HTML */ - public function onHtmlReady( $html ) { + public function onHtmlReady( string $html ): string { if ( $this->plainText ) { $html = preg_replace( '/\s*(getDoc();