<?php

namespace DefStudio\GameEngine\Actions\Teams;

use DefStudio\Actions\Action;
use Illuminate\Support\Facades\Gate;
use DefStudio\GameEngine\Models\Team;

/**
 * @method static void run(Team $team)
 */
class DeleteTeam extends Action
{
    public function handle(Team $team): void
    {
        Gate::authorize('delete', $team);

        $team->delete();
    }
}
