Conditions | 1 |
Paths | 1 |
Total Lines | 19 |
Code Lines | 12 |
Lines | 0 |
Ratio | 0 % |
Tests | 7 |
CRAP Score | 1.048 |
Changes | 0 |
1 | <?php |
||
16 | 1 | public function __construct() |
|
17 | { |
||
18 | 1 | $this->channelType = \Illuminate\Broadcasting\PrivateChannel::class; |
|
19 | 1 | $this->channelAuthName = 'App.Models.User.{userId}'; |
|
20 | 1 | $this->channelAuthCallback = static function (User $user, $userId) { |
|
21 | return (int) $user->id === (int) $userId; |
||
22 | }; |
||
23 | 1 | $this->channelContextBindingCallback = static function (Request $request) { |
|
24 | return [ |
||
25 | 'userId' => $request->user()->id |
||
26 | ]; |
||
27 | }; |
||
28 | 1 | $this->eventChannelIdentifierBindingCallback = static function (HasDynamicChannelFormula $event) { |
|
29 | $self = $event; |
||
30 | return [ |
||
31 | 'userId' => $self->userId, |
||
32 | ]; |
||
33 | }; |
||
34 | 1 | parent::__construct(); |
|
35 | 1 | } |
|
37 |
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