<?php
/**
 * Fired during plugin deactivation.
 *
 * @package Freelance_Studio
 */

class FS_Deactivator {

    /**
     * Deactivate the plugin.
     *
     * Clean up scheduled events but preserve all data.
     */
    public static function deactivate() {
        // Clear any scheduled cron events
        wp_clear_scheduled_hook('fs_daily_tasks');
        wp_clear_scheduled_hook('fs_send_invoice_reminders');
        wp_clear_scheduled_hook('fs_generate_recurring_invoices');
        wp_clear_scheduled_hook('fs_send_payment_reminders');
        wp_clear_scheduled_hook('fs_generate_recurring_tasks');
        
        error_log('Freelance Studio: Plugin deactivated');
    }
}
