HEX
Server: LiteSpeed
System: Linux server801.shared.spaceship.host 4.18.0-553.54.1.lve.el8.x86_64 #1 SMP Wed Jun 4 13:01:13 UTC 2025 x86_64
User: yvigantdvn (2232)
PHP: 8.3.30
Disabled: NONE
Upload Files
File: /home/yvigantdvn/petermkufya.com/wp-content/plugins/social-wall_2.4.0_2/uninstall.php
<?php
if ( ! defined( 'WP_UNINSTALL_PLUGIN' ) ) {
	exit();
}

//If the user is preserving the settings then don't delete them
$options = get_option( 'sbsw_settings' );
$sbsw_preserve_settings = isset( $options['preserve_settings'] ) ? $options['preserve_settings'] : false;

// allow the user to preserve their settings in case they are upgrading
if ( ! $sbsw_preserve_settings ) {

	// clear cron jobs
	wp_clear_scheduled_hook( 'sbsw_feed_update' );

	// clean up options from the database
	delete_option( 'sbsw_settings' );
	delete_option( 'sbsw_cron_report' );
	delete_option( 'sbsw_errors' );
	delete_option( 'sbsw_db_version' );

	// delete role
	global $wp_roles;
	$wp_roles->remove_cap( 'administrator', 'manage_social_wall_options' );
}