query( 'SET FOREIGN_KEY_CHECKS = 0' ); // foreach ( $rsv_tables as $rsv_table ) { // $table_name = $wpdb->prefix . $rsv_table; // Static, prefixed identifier — safe to interpolate. // $wpdb->query( "DROP TABLE IF EXISTS `{$table_name}`" ); // } // $wpdb->query( 'SET FOREIGN_KEY_CHECKS = 1' ); // Remove the plugin's options. $rsv_options = [ 'rsv_google_access_token', 'rsv_google_refresh_token', 'rsv_google_sync_token', 'rsv_google_token_expires', 'rsv_google_calendar_id', 'rsv_google_client_id', 'rsv_google_client_secret', 'rsv_google_webhook_channel_id', 'rsv_google_webhook_expiration', 'rsv_google_webhook_resource_id', ]; foreach ( $rsv_options as $rsv_option ) { delete_option( $rsv_option ); } // Remove the custom capability from every role. RsvCapabilities::revoke();