1 | <?php |
||
2 | |||
3 | namespace Insenseanalytics\NovaBarMetrics; |
||
4 | |||
5 | use InvalidArgumentException; |
||
6 | use Illuminate\Database\Eloquent\Builder; |
||
0 ignored issues
–
show
|
|||
7 | |||
8 | class FrequencyDistributionExpressionFactory |
||
9 | { |
||
10 | /** |
||
11 | * Create a new trend expression instance. |
||
12 | * |
||
13 | * @param \Illuminate\Database\Eloquent\Builder $query |
||
14 | * @param string $column |
||
15 | * @param int $stepSize |
||
16 | * |
||
17 | * @return \Laravel\Nova\Metrics\FrequencyDistributionExpression |
||
0 ignored issues
–
show
The type
Laravel\Nova\Metrics\Fre...yDistributionExpression was not found. Maybe you did not declare it correctly or list all dependencies?
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. filter:
dependency_paths: ["lib/*"]
For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths ![]() |
|||
18 | */ |
||
19 | public static function make(Builder $query, $column, $stepSize) |
||
20 | { |
||
21 | switch ($query->getConnection()->getDriverName()) { |
||
22 | case 'sqlite': |
||
23 | return new SqliteFrequencyDistributionExpression($query, $column, $stepSize); |
||
0 ignored issues
–
show
|
|||
24 | case 'mysql': |
||
25 | return new MySqlFrequencyDistributionExpression($query, $column, $stepSize); |
||
0 ignored issues
–
show
|
|||
26 | case 'pgsql': |
||
27 | return new PostgresFrequencyDistributionExpression($query, $column, $stepSize); |
||
0 ignored issues
–
show
|
|||
28 | default: |
||
29 | throw new InvalidArgumentException('Bar chart metric helpers are not supported for this database.'); |
||
30 | } |
||
31 | } |
||
32 | } |
||
33 |
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