From 9ae854e58ca43e6ca777de1922c5431931536354 Mon Sep 17 00:00:00 2001 From: Bart Jaskulski <bjaskulski@protonmail.com> Date: Thu, 9 Feb 2023 12:44:24 +0100 Subject: [PATCH] refactor: remove arrow from strings Remove arrows from user-facing messages due to Automattic requirement derived from malware scanning. Those strings are interpreted as NonPrintableCharacters in YARA rules and disables our plugin from successful submission to woocommerce.com repository. Signed-off-by: Bart Jaskulski <bjaskulski@protonmail.com> --- src/Basic_Requirement_Checker.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Basic_Requirement_Checker.php b/src/Basic_Requirement_Checker.php index 239b2e4..e942fff 100644 --- a/src/Basic_Requirement_Checker.php +++ b/src/Basic_Requirement_Checker.php @@ -453,7 +453,7 @@ if ( ! class_exists( 'WPDesk_Basic_Requirement_Checker' ) ) { if ( ! self::is_wp_plugin_installed( $name ) ) { $install_url = $this->prepare_plugin_repository_install_url( $plugin_info ); - return $this->prepare_notice_message( sprintf( wp_kses( __( 'The “%s” plugin requires free %s plugin. <a href="%s">Install %s →</a>', + return $this->prepare_notice_message( sprintf( wp_kses( __( 'The “%s” plugin requires free %s plugin. <a href="%s">Install %s</a>', $this->get_text_domain() ), array( 'a' => array( 'href' => array() ) ) ), $this->plugin_name, $nice_name, esc_url( $install_url ), $nice_name ) ); } @@ -462,7 +462,7 @@ if ( ! class_exists( 'WPDesk_Basic_Requirement_Checker' ) ) { $activate_url .= '&_wpnonce=' . urlencode( wp_create_nonce( 'activate-plugin_' . $name ) ); } - return $this->prepare_notice_message( sprintf( wp_kses( __( 'The “%s” plugin requires activating %s plugin. <a href="%s">Activate %s →</a>', + return $this->prepare_notice_message( sprintf( wp_kses( __( 'The “%s” plugin requires activating %s plugin. <a href="%s">Activate %s</a>', $this->get_text_domain() ), array( 'a' => array( 'href' => array() ) ) ), $this->plugin_name, $nice_name, esc_url( admin_url( $activate_url ) ), $nice_name ) ); } @@ -630,4 +630,4 @@ if ( ! class_exists( 'WPDesk_Basic_Requirement_Checker' ) ) { } } } -} \ No newline at end of file +} -- GitLab