tenant()->id, 'email' => tenant()->email, 'email_verified_at' => now(), 'password' => Hash::make(tenant()->id), 'remember_token' => Str::random(10), 'username' => tenant()->id, 'company_id' => Company::query()->firstOrCreate(['name' => tenant()->id, 'email' => tenant()->email]), 'role_id' => config("auth.super_admin_role_id") ]); $role = Role::query()->findOrFail($user['role_id']); $user->syncRoles($role); } }