24 lines
522 B
PHP
24 lines
522 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace Database\Factories\Engelsystem\Models\User;
|
|
|
|
use Engelsystem\Models\User\PasswordReset;
|
|
use Engelsystem\Models\User\User;
|
|
use Illuminate\Database\Eloquent\Factories\Factory;
|
|
|
|
class PasswordResetFactory extends Factory
|
|
{
|
|
/** @var string */
|
|
protected $model = PasswordReset::class; // phpcs:ignore
|
|
|
|
public function definition(): array
|
|
{
|
|
return [
|
|
'user_id' => User::factory(),
|
|
'token' => bin2hex(random_bytes(16)),
|
|
];
|
|
}
|
|
}
|