Conditions | 8 |
Paths | 7 |
Total Lines | 30 |
Code Lines | 17 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
49 | public function __invoke() |
||
50 | { |
||
51 | $isSitePublic = ('on' === EBB\Options::getOption('site_publication')); |
||
52 | |||
53 | if (! $isSitePublic && (! $this->hasAuthenticatedUser() || ! $this->getAcl()->isUserAllowed($this->getAuthenticatedUser(), 'Donor', 'read'))) { |
||
54 | $this->viewFactory->displayView('error-403'); |
||
55 | return; |
||
56 | } |
||
57 | |||
58 | if ($this->donorId) { |
||
59 | $this->donor = $this->getDonorRepository()->find($this->donorId); |
||
60 | } |
||
61 | |||
62 | if (! $this->donor) { |
||
63 | $this->viewFactory->displayView('error-404'); |
||
64 | return; |
||
65 | } |
||
66 | |||
67 | $donor = $this->donor; |
||
68 | |||
69 | if ($this->hasAuthenticatedUser() && ! $this->getAcl()->canReadEntity($this->getAuthenticatedUser(), $donor)) { |
||
70 | $this->viewFactory->displayView('error-403'); |
||
71 | return; |
||
72 | } |
||
73 | |||
74 | $this->addNotices(); |
||
75 | $this->viewFactory->displayView( |
||
76 | 'view-donor', |
||
77 | [ |
||
78 | 'donor' => $donor, |
||
79 | ] |
||
94 |
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