| Total Complexity | 6 |
| Total Lines | 41 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 14 | #[Entity(repository: IdentityRepository::class)] |
||
| 15 | class Identity implements CookieLoginIdentityInterface |
||
| 16 | { |
||
| 17 | #[Column(type: 'primary')] |
||
| 18 | private ?int $id = null; |
||
| 19 | |||
| 20 | #[Column(type: 'string(32)')] |
||
| 21 | private string $authKey; |
||
| 22 | |||
| 23 | #[BelongsTo(target: User::class, nullable: false, load: 'eager')] |
||
| 24 | private ?User $user = null; |
||
| 25 | private ?int $user_id = null; |
||
| 26 | |||
| 27 | public function __construct() |
||
| 28 | { |
||
| 29 | $this->regenerateCookieLoginKey(); |
||
| 30 | } |
||
| 31 | |||
| 32 | public function getId(): ?string |
||
| 33 | { |
||
| 34 | return $this->user->getId(); |
||
| 35 | } |
||
| 36 | |||
| 37 | public function getCookieLoginKey(): string |
||
| 38 | { |
||
| 39 | return $this->authKey; |
||
| 40 | } |
||
| 41 | |||
| 42 | public function getUser(): ?User |
||
| 43 | { |
||
| 44 | return $this->user; |
||
| 45 | } |
||
| 46 | |||
| 47 | public function validateCookieLoginKey(string $key): bool |
||
| 48 | { |
||
| 49 | return $this->authKey === $key; |
||
| 50 | } |
||
| 51 | |||
| 52 | public function regenerateCookieLoginKey(): void |
||
| 55 | } |
||
| 56 | } |
||
| 57 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths