From 1f36e2b3fd6af08159dd001ecd00a4396a0ac657 Mon Sep 17 00:00:00 2001 From: Mohamad Nateqi Rostami Date: Fri, 22 Nov 2024 12:59:59 +0330 Subject: [PATCH] Improvements --- includes/Settings/SettingsDebug.php | 28 +++++++++++++++------------- views/advanced-status.php | 3 --- 2 files changed, 15 insertions(+), 16 deletions(-) diff --git a/includes/Settings/SettingsDebug.php b/includes/Settings/SettingsDebug.php index 37afedaff..4db30def9 100644 --- a/includes/Settings/SettingsDebug.php +++ b/includes/Settings/SettingsDebug.php @@ -76,12 +76,23 @@ public function display_settings() { submit_button(); } - public function display_status() { - include( WPO_WCPDF()->plugin_path() . '/views/advanced-status.php' ); + /** + * Display the server requirement page. + * + * @return void + */ + public function display_status(): void { + $server_configs = $this->get_server_config(); + include WPO_WCPDF()->plugin_path() . '/views/advanced-status.php'; } - public function display_tools() { - include( WPO_WCPDF()->plugin_path() . '/views/advanced-tools.php' ); + /** + * Display the advanced tools page. + * + * @return void + */ + public function display_tools(): void { + include WPO_WCPDF()->plugin_path() . '/views/advanced-tools.php'; } public function display_numbers() { @@ -1053,15 +1064,6 @@ public function get_server_config(): array { } } - if ( ! $server_configs['PHP version']['result'] ) { - $server_configs['PHP version']['required'] .= '
' . sprintf( - /* translators: tags */ - __( 'Download %1$sthis addon%2$s to enable backwards compatibility.', 'woocommerce-pdf-invoices-packing-slips' ), - '', - '' - ); - } - return apply_filters( 'wpo_wcpdf_server_configs', $server_configs ); } diff --git a/views/advanced-status.php b/views/advanced-status.php index 47c06ca20..479b23b31 100644 --- a/views/advanced-status.php +++ b/views/advanced-status.php @@ -2,9 +2,6 @@ if ( ! defined( 'ABSPATH' ) ) { exit; // Exit if accessed directly } - -$server_configs = $this->get_server_config(); - ?>