I edited the phpDoc from @param \Illuminate\Database\Eloquent\Relations\Relation<*, *, *>|string $relation to @param \Illuminate\Database\Eloquent\Relations\Relation|string $relation, then cleared the cache > Clear /vendor/ cache. and then the error disappears :)
I think php tools does not parse this part of Doc correctly. although it seems to appear a lot on laravel
