Conditions | 3 |
Paths | 4 |
Total Lines | 17 |
Code Lines | 12 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
17 | public function discoveryBotUser(): User |
||
18 | { |
||
19 | if (!self::$botUser) |
||
20 | $bots = ['R2D2', 'C3PO', 'T800', 'SkyNet']; |
||
21 | |||
22 | $online = array_rand($bots); |
||
23 | $bot = $bots[$online]; |
||
24 | |||
25 | self::$botUser = $this->manager->getRepository(User::class)->findOneBy(['username' => $bot]); |
||
26 | if (!self::$botUser) { |
||
27 | self::$botUser = new User(); |
||
28 | self::$botUser->setUserName($bot); |
||
29 | self::$botUser->setHash('872844840.0'); |
||
30 | $this->manager->persist(self::$botUser); |
||
31 | $this->manager->flush(); |
||
32 | } |
||
33 | return self::$botUser; |
||
34 | } |
||
40 |
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