It seems like \Member::currentUser() targeting Member::currentUser() can also be of type object<DataObject>; however, DataObject::canView() does only seem to accept object<Member>|null, maybe add an additional type check?
This check looks at variables that are passed out again to other methods.
If the outgoing method call has stricter type requirements than the method itself, an issue is raised.
An additional type check may prevent trouble.
Loading history...
40
return $this->getController()->customise([
41
'WishList' => $record,
42
'Breadcrumbs' => $record->Breadcrumbs(),
43
'ProductWishListForm' => false,
44
]);
45
}
46
47
1
return Security::permissionFailure($this->owner, "You don't have permission to view this record.");
48
}
49
50
return $this->getController()->httpError(404);
51
}
52
53
/**
54
* @param $collection
55
* @param $searchCriteria
56
*/
57
public function updateCollectionItems(&$collection, $searchCriteria)
This check looks at variables that are passed out again to other methods.
If the outgoing method call has stricter type requirements than the method itself, an issue is raised.
An additional type check may prevent trouble.