It seems like app(App\Classes\Reposito...pository::class)->all() can also be of type Illuminate\Database\Eloquent\Builder and App\Model\Setting; however, parameter $collection of App\Classes\SettingsManager::collect() does only seem to accept Illuminate\Support\Collection, maybe add an additional type check?
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the ignore-type annotation
44
return (new SettingsManager)->collect(/** @scrutinizer ignore-type */ app(SettingsRepository::class)->all());
Loading history...
45
} catch (Exception $e) {
46
if ($this->app->runningInConsole()) {
47
return new SettingsManager;
48
}
49
50
throw new EngineBootException('Could not perform query on the `settings database`, do we have proper connection settings?');
51
}
52
});
53
}
54
55
private function makePluginInstance()
56
{
57
$this->app->singleton(PluginManager::class, function () {
58
try {
59
return (new PluginManager)->collect(app(PluginRepository::class)->all());
It seems like app(App\Classes\Reposito...pository::class)->all() can also be of type App\Model\Plugin and Illuminate\Database\Eloquent\Builder; however, parameter $collection of App\Classes\PluginManager::collect() does only seem to accept Illuminate\Support\Collection, maybe add an additional type check?
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the ignore-type annotation
59
return (new PluginManager)->collect(/** @scrutinizer ignore-type */ app(PluginRepository::class)->all());
Loading history...
60
} catch (Exception $e) {
61
if ($this->app->runningInConsole()) {
62
return new PluginManager;
63
}
64
65
throw new EngineBootException('Could not perform query on the `plugins database`, do we have proper connection settings?');