fomvasss /
laravel-variables
| 1 | <?php |
||||
| 2 | |||||
| 3 | namespace Fomvasss\Variable\Commands; |
||||
| 4 | |||||
| 5 | use Illuminate\Console\Command; |
||||
|
0 ignored issues
–
show
|
|||||
| 6 | |||||
| 7 | class AllVariable extends Command |
||||
| 8 | { |
||||
| 9 | protected $signature = 'variable:all |
||||
| 10 | {--langcode= : The language code} |
||||
| 11 | {--cache=true : Use cache}'; |
||||
| 12 | |||||
| 13 | protected $description = 'Get all variables'; |
||||
| 14 | |||||
| 15 | public function handle() |
||||
| 16 | { |
||||
| 17 | $variableMng = app(\Fomvasss\Variable\VariableManagerContract::class); |
||||
|
0 ignored issues
–
show
The function
app was not found. Maybe you did not declare it correctly or list all dependencies?
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the
Loading history...
|
|||||
| 18 | |||||
| 19 | $useCache = in_array($this->option('cache'), ['0', 'false', false]) ? false : true; |
||||
| 20 | $variables = $variableMng |
||||
| 21 | ->all($this->option('langcode'), $useCache); |
||||
| 22 | |||||
| 23 | foreach ($variables as $item) { |
||||
| 24 | $this->info("$item->key [$item->langcode] : $item->value"); |
||||
| 25 | } |
||||
| 26 | } |
||||
| 27 | } |
||||
| 28 |
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