← Back
Editing: uninstall.php
<?php /** * HelloPack Client uninstall. * * @package HelloPack\Client */ if ( ! defined( 'WP_UNINSTALL_PLUGIN' ) ) { exit; } require_once __DIR__ . '/vendor/autoload.php'; // The licence modules copied the API key into the managed plugins' settings. // Read the keys now, while HelloPack's own options still hold them. $hellopack_key_scrubber = new \HelloPack\Client\License\KeyScrubber( \HelloPack\Client\License\KeyScrubber::collect_keys( 'hellopack_client' ) ); // Delete options. delete_option( 'hellopack_client' ); delete_site_option( 'hellopack_client' ); delete_option( 'hellopack_client-status' ); delete_site_option( 'hellopack_client-status' ); delete_option( 'hellopack_client-status-endpoint' ); delete_site_option( 'hellopack_client-status-endpoint' ); delete_option( 'hellopack_client-status-endpoint-cache' ); delete_site_option( 'hellopack_client-status-endpoint-cache' ); delete_option( 'hellopack_client-status-endpoint-samples' ); delete_site_option( 'hellopack_client-status-endpoint-samples' ); delete_option( 'hellopack_modules_settings' ); delete_site_option( 'hellopack_modules_settings' ); // Delete transients. delete_site_transient( 'hellopack_client_plugins' ); delete_site_transient( 'hellopack_client_themes' ); delete_transient( 'hellopack_client_plugins' ); delete_transient( 'hellopack_client_themes' ); delete_transient( 'hellopack_last_auth_check' ); delete_transient( 'hellopack_cron_check' ); delete_transient( 'hellopack_reauth_retry_count' ); delete_transient( 'hellopack_health_remote' ); // Clear scheduled hooks. wp_clear_scheduled_hook( 'hellopack_check_authorization' ); // Remove the API key from every other plugin's settings. $hellopack_key_scrubber->scrub();
Save File
Cancel