It seems like $this->validation can also be of type null; however, parameter $validation of Rakit\Validation\Rule::setValidation() does only seem to accept Rakit\Validation\Validation, 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
It seems like $this->attribute can also be of type null; however, parameter $attribute of Rakit\Validation\Rule::setAttribute() does only seem to accept Rakit\Validation\Attribute, 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