It seems like $records can also be of type Illuminate\Database\Eloquent\Builder; however, parameter $records of Apps\Model\Admin\Content...entClear::__construct() does only seem to accept Apps\ActiveRecord\Conten...ase\Eloquent\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
32
$model = new FormContentClear(/** @scrutinizer ignore-type */ $records);
Loading history...
33
if ($model->send() && $model->validate()) {
34
$model->make();
35
App::$Session->getFlashBag()->add('success', __('Trash content is cleaned'));