From e94ef7b84b3d05516067379b43eb2872b865edfc Mon Sep 17 00:00:00 2001 From: Josh Knapp Date: Tue, 22 Apr 2025 13:46:42 -0700 Subject: [PATCH] Remove Debug Code for version --- libs/self-update.php | 26 ++------------------------ 1 file changed, 2 insertions(+), 24 deletions(-) diff --git a/libs/self-update.php b/libs/self-update.php index ab99dcc..dfb5359 100644 --- a/libs/self-update.php +++ b/libs/self-update.php @@ -48,11 +48,6 @@ function fwembed_check_for_updates() { if ($response) { $release_info = json_decode($response); - // Update debug info with latest version - $debug_data['latest_version'] = $release_info->tag_name ?? 'Not found'; - $debug_data['response'] = substr(print_r($release_info, true), 0, 1000); - update_option('fwembed_update_debug', $debug_data); - // Get latest version from tag name $latest_version = $release_info->tag_name; @@ -96,8 +91,8 @@ function fwembed_check_for_updates() { 'package' => $download_url, 'icons' => [], 'banners' => [], - 'tested' => '6.4.2', - 'requires' => '5.0', + 'tested' => '6.8', + 'requires' => '6.2', 'compatibility' => new stdClass(), ]; @@ -108,23 +103,6 @@ function fwembed_check_for_updates() { } add_action('admin_init', 'fwembed_check_for_updates'); -// Add admin notice for debugging -add_action('admin_notices', function() { - if (current_user_can('manage_options')) { - $debug = get_option('fwembed_update_debug', []); - echo '

Update Debug: Current: ' . - esc_html($debug['current_version'] ?? 'N/A') . ', Latest: ' . - esc_html($debug['latest_version'] ?? 'N/A') . '

'; - - // Detailed debug info with query param - if (isset($_GET['fwembed_debug'])) { - echo '
' . esc_html(print_r($debug, true)) . '
'; - } - - echo '
'; - } -}); - // Add plugin information for the details popup/changelog add_filter('plugins_api', function($result, $action, $args) {