@@ -368,11 +368,11 @@ protected static function upgrade_install() {
368368 protected static function get_upgrade_sequence () {
369369 $ upgrade_sequence = array ();
370370 $ sequences = array (
371- '3.0.0 ' => array (
371+ '3.0.0 ' => array (
372372 'range ' => array ( '3.0.0 ' ),
373373 'method ' => array ( 'Cloudinary\Utils ' , 'upgrade_3_0_1 ' ),
374374 ),
375- '3.1.9 ' => array (
375+ '3.1.9 ' => array (
376376 'range ' => array ( '3.0.1 ' , '3.1.9 ' ),
377377 'method ' => array ( 'Cloudinary\Utils ' , 'upgrade_3_1_9 ' ),
378378 ),
@@ -1384,12 +1384,12 @@ public static function get_transformations_title( $context ) {
13841384 /**
13851385 * Get inline SVG content safely.
13861386 *
1387- * @param string $file_path The absolute or relative path to the SVG file.
1388- * @param bool $echo Whether to echo the SVG content or return it. Default true.
1387+ * @param string $file_path The absolute or relative path to the SVG file.
1388+ * @param bool $output_content Whether to echo the SVG content or return it. Default true.
13891389 *
13901390 * @return string|void The SVG content if $echo is false, void otherwise.
13911391 */
1392- public static function get_inline_svg ( $ file_path , $ echo = true ) {
1392+ public static function get_inline_svg ( $ file_path , $ output_content = true ) {
13931393 // If relative path, make it absolute from plugin root.
13941394 if ( ! file_exists ( $ file_path ) ) {
13951395 $ plugin_dir = dirname ( __DIR__ );
@@ -1402,7 +1402,7 @@ public static function get_inline_svg( $file_path, $echo = true ) {
14021402 }
14031403
14041404 // Get the SVG content.
1405- $ svg_content = file_get_contents ( $ file_path ); // phpcs:ignore WordPress.WP.AlternativeFunctions.file_get_contents_file_get_contents
1405+ $ svg_content = file_get_contents ( $ file_path ); // phpcs:ignore WordPress.WP.AlternativeFunctions.file_get_contents_file_get_contents, WordPressVIPMinimum.Performance.FetchingRemoteData.FileGetContentsUnknown
14061406
14071407 if ( false === $ svg_content ) {
14081408 return '' ;
@@ -1411,7 +1411,7 @@ public static function get_inline_svg( $file_path, $echo = true ) {
14111411 // Sanitize SVG content to prevent XSS attacks.
14121412 $ svg_content = self ::sanitize_svg ( $ svg_content );
14131413
1414- if ( $ echo ) {
1414+ if ( $ output_content ) {
14151415 echo $ svg_content ; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- Sanitized by sanitize_svg.
14161416 } else {
14171417 return $ svg_content ;
0 commit comments