| Conditions | 3 |
| Paths | 5 |
| Total Lines | 17 |
| Code Lines | 11 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 36 | public function downloadFile($file, $base64Encode = false) { |
||
| 37 | try { |
||
| 38 | $this->logger->debug( |
||
| 39 | "[DownloadService] File to Download: {name}", ['name' => $file->getName()] |
||
| 40 | ); |
||
| 41 | $download = [ |
||
| 42 | 'preview' => $file->getContent(), |
||
| 43 | 'mimetype' => $file->getMimeType() |
||
| 44 | ]; |
||
| 45 | |||
| 46 | if ($base64Encode) { |
||
| 47 | $download['preview'] = $this->encode($download['preview']); |
||
| 48 | } |
||
| 49 | |||
| 50 | return $download; |
||
| 51 | } catch (\Exception $exception) { |
||
| 52 | throw new NotFoundServiceException('There was a problem accessing the file'); |
||
| 53 | } |
||
| 58 |
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