From 5411e4b279cf58853b84f8f5edabbb4185a631e0 Mon Sep 17 00:00:00 2001 From: Rumperuu Date: Tue, 23 Feb 2021 17:17:14 +0000 Subject: [PATCH] Replace `wp_remote_get()` with PHPCS disable. --- class/template.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/class/template.php b/class/template.php index d438748..4a6bff1 100644 --- a/class/template.php +++ b/class/template.php @@ -162,7 +162,9 @@ class MCI_Footnotes_Template { * @since 2.5.4 Collapse HTML comments and PHP/JS docblocks (only). */ public function process_template( $template ) { - $this->a_str_original_content = preg_replace( '##s', '', wp_remote_get( $template ) ); + // phpcs:disable WordPress.WP.AlternativeFunctions.file_get_contents_file_get_contents + $this->a_str_original_content = preg_replace( '##s', '', file_get_contents( $template ) ); + // phpcs:enable $this->a_str_original_content = preg_replace( '#/\*\*.+?\*/#s', '', $this->a_str_original_content ); $this->a_str_original_content = str_replace( "\n", '', $this->a_str_original_content ); $this->a_str_original_content = str_replace( "\r", '', $this->a_str_original_content );