Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
| Total | |
0.00% |
0 / 9 |
n/a |
0 / 0 |
CRAP | n/a |
0 / 0 |
||
| 1 | <?php |
| 2 | /** |
| 3 | * Fired when the plugin is uninstalled. |
| 4 | * |
| 5 | * When populating this file, consider the following flow |
| 6 | * of control: |
| 7 | * |
| 8 | * - This method should be static |
| 9 | * - Check if the $_REQUEST content actually is the plugin name |
| 10 | * - Run an admin referrer check to make sure it goes through authentication |
| 11 | * - Verify the output of $_GET makes sense |
| 12 | * - Repeat with other user roles. Best directly by using the links/query string parameters. |
| 13 | * - Repeat things for multisite. Once for a single site in the network, once sitewide. |
| 14 | * |
| 15 | * This file may be updated more in future version of the Boilerplate; however, this is the |
| 16 | * general skeleton and outline for how the file should work. |
| 17 | * |
| 18 | * For more information, see the following discussion: |
| 19 | * https://github.com/tommcfarlin/WordPress-Plugin-Boilerplate/pull/123#issuecomment-28541913 |
| 20 | * |
| 21 | * @link https://BrianHenryIE.com |
| 22 | * @since 1.0.0 |
| 23 | * |
| 24 | * @package BH_WC_Checkout_Rate_Limiter |
| 25 | */ |
| 26 | |
| 27 | // If uninstall not called from WordPress, then exit. |
| 28 | if ( ! defined( 'WP_UNINSTALL_PLUGIN' ) ) { |
| 29 | exit; |
| 30 | } |
| 31 | |
| 32 | delete_option( 'bh_wc_checkout_rate_limiter_activated_time' ); |
| 33 | delete_option( 'bh_wc_checkout_rate_limiter_deactivated_time' ); |
| 34 | |
| 35 | delete_option( 'bh_wc_checkout_rate_limiter_checkout_rate_limiting_enabled' ); |
| 36 | |
| 37 | delete_option( 'bh_wc_checkout_rate_limiter_allowed_attempts_per_interval_1' ); |
| 38 | delete_option( 'bh_wc_checkout_rate_limiter_allowed_attempts_per_interval_2' ); |
| 39 | delete_option( 'bh_wc_checkout_rate_limiter_allowed_attempts_per_interval_3' ); |
| 40 | |
| 41 | delete_option( 'bh_wc_checkout_rate_limiter_log_level' ); |