updates ) && is_array( $update_data->updates ) ) { foreach ( $update_data->updates as $update ) { if ( 'upgrade' === $update->response ) { $needs_update = true; break; } } } if ( ! $needs_update ) { return array(); } return array( $this->make_result( array( 'id' => 'wp_outdated', 'title' => __( 'WordPress core is outdated', 'aipatch-security-scanner' ), 'description' => sprintf( /* translators: %s: Installed WordPress version. */ __( 'You are running WordPress %s. A newer version is available.', 'aipatch-security-scanner' ), $wp_version ), 'severity' => 'high', 'confidence' => 'high', 'category' => 'core', 'why_it_matters' => __( 'Outdated WordPress versions may contain known security vulnerabilities that attackers can exploit.', 'aipatch-security-scanner' ), 'recommendation' => __( 'Update WordPress to the latest version from Dashboard → Updates.', 'aipatch-security-scanner' ), 'dismissible' => false, 'evidence' => sprintf( 'Installed: %s', $wp_version ), ) ), ); } }