Started work on user slugs

Related to #2525
This commit is contained in:
Dan Brown
2021-03-08 22:34:22 +00:00
parent 34e6098687
commit 3a9caea846
6 changed files with 98 additions and 34 deletions

View File

@ -12,9 +12,11 @@
*/
$factory->define(\BookStack\Auth\User::class, function ($faker) {
$name = $faker->name;
return [
'name' => $faker->name,
'name' => $name,
'email' => $faker->email,
'slug' => \Illuminate\Support\Str::slug($name . '-' . \Illuminate\Support\Str::random(5)),
'password' => Str::random(10),
'remember_token' => Str::random(10),
'email_confirmed' => 1