Total Complexity | 2 |
Total Lines | 31 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
10 | class PdfService |
||
11 | { |
||
12 | |||
13 | |||
14 | public function showPdf($content) |
||
15 | { |
||
16 | $response = new StreamedResponse(function () use ($content) { |
||
17 | fputs(fopen('php://output', 'wb'), $content); |
||
18 | }); |
||
19 | |||
20 | $response->headers->set('Content-Type', 'application/pdf'); |
||
21 | |||
22 | $disposition = HeaderUtils::makeDisposition(HeaderUtils::DISPOSITION_INLINE, 'contract.pdf'); |
||
23 | |||
24 | $response->headers->set('Content-Disposition', $disposition); |
||
25 | |||
26 | return $response; |
||
27 | } |
||
28 | |||
29 | public function convertHtmlToPdf($html): string |
||
41 | } |
||
42 | } |
||
43 |
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