diff --git a/skolehjem/database/seeds/UserSeeder.php b/skolehjem/database/seeds/UserSeeder.php index 389d003..d90fae8 100644 --- a/skolehjem/database/seeds/UserSeeder.php +++ b/skolehjem/database/seeds/UserSeeder.php @@ -2,6 +2,7 @@ use App\User; use Illuminate\Database\Seeder; +use Illuminate\Support\Facades\Log; class UserSeeder extends Seeder { @@ -13,12 +14,19 @@ class UserSeeder extends Seeder public function run() { - try { - if(User::findByName("admin")) - return; - } catch (Exception $e) { +// try { +// +// } catch (Exception $e) { +// } + + Log::debug("YEET"); + + if(User::where("name_first", "admin")) + { + return; } + Log::debug("OPRET"); $user = new \App\User(); $user->name_first = "admin";