Skip to content
This repository has been archived by the owner on Sep 23, 2024. It is now read-only.

Patch/add files #11

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 0 additions & 33 deletions config/view.php

This file was deleted.

2 changes: 1 addition & 1 deletion database/factories/UserFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
'firstname' => $faker->name(),

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

category Bug Risk priority 8

The 'firstname' attribute is being populated with the full name instead of just the first name. This could lead to confusion and incorrect data being used in tests. Use the appropriate Faker method to generate only a first name.

'address' => $faker->streetAddress(),
'postal_code' => $faker->postcode(),
'city' => $faker->city(),
'city' => $faker -> city(),
'country' => $faker->state(),

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

category Bug Risk priority 8

The 'country' attribute is being populated with a state name instead of a country name. This could lead to incorrect or misleading data. Use the appropriate Faker method to generate a country name.

'password' => '$2y$10$TKh8H1.PfQx37YgCzwiKb.KjNyWgaHb9cbcoQgdIVFlYg7B77UdFm', // secret

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

category Security priority 6

Hardcoding the password in the user factory is a security risk, even if it's for testing purposes. It's better to use a hashed environment-specific value or a configuration setting to define default passwords for generated users.

'remember_token' => str_random(10)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

category Code Design Improvements priority 7

The 'str_random' function has been deprecated as of Laravel 5.8. It's recommended to use 'Illuminate\Support\Str::random' instead to generate a random string for the 'remember_token'.

Expand Down