<?php

use App\Models\Account\Account;
use Illuminate\Database\Seeder;
use Illuminate\Support\Facades\DB;
use App\Domains\Account\Services\AccountService;

class AccountSeeder extends Seeder
{
    /**
     * Run the database seeds.
     *
     * @return void
     */
    public function run()
    {
        if (Account::where('username', 'root')->count()) {
            return ;
        }

        app(AccountService::class)->store(['username' => 'root', 'password' => md5('root')]);
    }
}
