<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

return new class extends Migration
{
    public function up(): void
    {
        Schema::table('investment_settings', function (Blueprint $table): void {
            $table->boolean('require_kyc_to_invest')->default(true)->after('payment_address');
            $table->boolean('require_kyc_to_withdraw')->default(true)->after('require_kyc_to_invest');
        });
    }

    public function down(): void
    {
        Schema::table('investment_settings', function (Blueprint $table): void {
            $table->dropColumn(['require_kyc_to_invest', 'require_kyc_to_withdraw']);
        });
    }
};
