<?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('photos', function (Blueprint $table) {
            $table->string('security_scan_status')->default('pending')->after('metadata');
            $table->text('security_scan_message')->nullable()->after('security_scan_status');
            $table->timestamp('security_scanned_at')->nullable()->after('security_scan_message');
            $table->json('security_meta')->nullable()->after('security_scanned_at');
        });
    }

    public function down(): void
    {
        Schema::table('photos', function (Blueprint $table) {
            $table->dropColumn(['security_scan_status', 'security_scan_message', 'security_scanned_at', 'security_meta']);
        });
    }
};

