| Server IP : 170.10.161.225 / Your IP : 216.73.217.54 Web Server : Apache System : Linux vps103298.mylogin.co 4.18.0-513.11.1.el8_9.x86_64 #1 SMP Wed Jan 17 02:00:40 EST 2024 x86_64 User : calvet ( 273824) PHP Version : 7.4.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : ON Directory : /home/www/calvetrealty.com/wp-content/plugins/um-recaptcha/ |
Upload File : |
<?php
/**
* Uninstall UM Recaptcha
*
*/
// Exit if accessed directly.
if ( ! defined( 'WP_UNINSTALL_PLUGIN' ) ) {
exit;
}
if ( ! defined( 'UM_RECAPTCHA_PATH' ) ) {
define( 'UM_RECAPTCHA_PATH', plugin_dir_path( __FILE__ ) );
}
if ( ! defined( 'UM_RECAPTCHA_URL' ) ) {
define( 'UM_RECAPTCHA_URL', plugin_dir_url( __FILE__ ) );
}
if ( ! defined( 'UM_RECAPTCHA_PLUGIN' ) ) {
define( 'UM_RECAPTCHA_PLUGIN', plugin_basename( __FILE__ ) );
}
$options = get_option( 'um_options', array() );
if ( ! empty( $options['uninstall_on_delete'] ) ) {
if ( ! class_exists( 'um_ext\um_recaptcha\core\Setup' ) ) {
/** @noinspection PhpIncludeInspection */
require_once UM_RECAPTCHA_PATH . 'includes/core/class-setup.php';
}
$recaptcha_setup = new um_ext\um_recaptcha\core\Setup();
//remove settings
foreach ( $recaptcha_setup->settings_defaults as $k => $v ) {
unset( $options[ $k ] );
}
update_option( 'um_options', $options );
delete_option( 'um_recaptcha_last_version_upgrade' );
delete_option( 'um_recaptcha_version' );
}