<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Support\Facades\DB;

return new class extends Migration
{
    /**
     * Run the migrations.
     */
    public function up(): void
    {
        // Fix Balance Adjustment category icon from emoji to Font Awesome class
        DB::table('categories')
            ->where('slug', 'balance-adjustment')
            ->update([
                'icon' => 'balance-scale',
                'name' => 'Penyesuaian Saldo',
            ]);
    }

    /**
     * Reverse the migrations.
     */
    public function down(): void
    {
        DB::table('categories')
            ->where('slug', 'balance-adjustment')
            ->update([
                'icon' => '⚖️',
                'name' => 'Balance Adjustment',
            ]);
    }
};
