1 | <?php |
||
2 | |||
3 | namespace DeGraciaMathieu\Nero; |
||
4 | |||
5 | class Errors { |
||
6 | |||
7 | protected $executor; |
||
8 | |||
9 | public function __construct() |
||
10 | { |
||
11 | $this->executor = new Executor; |
||
12 | } |
||
13 | |||
14 | /** |
||
15 | * get a syntax error |
||
16 | * @param string $file |
||
17 | * @param integer $line |
||
18 | * @param string|null $parameter |
||
19 | * @return exit |
||
0 ignored issues
–
show
|
|||
20 | */ |
||
21 | public function syntaxError($file, $line, $parameter = null) |
||
22 | { |
||
23 | $message = "<b>Parse error</b>: syntax error, unexpected '%s' (T_STRING) in <b>%s</b> on line <b>%d</b>"; |
||
24 | |||
25 | $this->executor->send($message, $parameter, $file, $line); |
||
26 | } |
||
27 | |||
28 | /** |
||
29 | * get a class not found error |
||
30 | * @param string $file |
||
31 | * @param integer $line |
||
32 | * @param string|null $parameter |
||
33 | * @return exit |
||
34 | */ |
||
35 | public function classNotFound($file, $line, $parameter = 'Exception') |
||
36 | { |
||
37 | $message = "<b>Fatal error</b>: Uncaught Error: Class '%s' not found in <b>%s</b>:<b>%d</b>"; |
||
38 | |||
39 | $this->executor->send($message, $parameter, $file, $line); |
||
40 | } |
||
41 | } |
||
42 |
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