tom3
Active member
Based on permissions in a template, I would like to display the Payment Provider Log per user. However, I have problems displaying the objects, because they are protected. How can I solve this?
Error: Cannot access protected property XF\Mvc\Entity\ArrayCollection::$entities
PHP:
$entries = \XF::finder('XF:PaymentProviderLog')
->order('provider_log_id', 'DESC');
$user = \XF::em()->find('XF:User', $params[0]);
$logs = $entries->where('PurchaseRequest.user_id', $user->user_id)
->fetch();
Error: Cannot access protected property XF\Mvc\Entity\ArrayCollection::$entities