database/seeders/UserSeeder.php
/**
     * Run the database seeds.
     *
     * @return void
     */
Run the database seeds.
@return void
Run the database seeds . @return void
public function run()
    {
        if (!User::where('email', 'test@gmail.com')->first()) {
            User::create([
                'name' => config('app.name'),
                'email' => 'admin@gmail.com',
                'password' => bcrypt('test1234')
            ]);
        }
    }
public function run ( ) { if ( ! User :: where ( 'email' , 'test@gmail.com' ) -> first ( ) ) { User :: create ( [ 'name' => config ( 'app.name' ) , 'email' => 'admin@gmail.com' , 'password' => bcrypt ( 'test1234' ) ] ) ; } }
Run the database seeds.
Run the database seeds .