Marcus
Well-known member
This from a callback returns an error:
This is returning a similar error:
This returns a different error:
Do you know what causes the error? What is the right way to access a model from xen:callback?
PHP:
$threads = XenForo_Model::create('XenForo_Model_Thread')->getThreads(
array('discussion_state' => 'visible')
);
Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 41 bytes) in ...\library\Zend\Db\Statement\Mysqli.php on line 304
This is returning a similar error:
PHP:
$threadModel = new XenForo_Model_Thread;
$threads = $threadModel->getThreads(
array('discussion_state' => 'visible'), $fetchOptions
);
This returns a different error:
PHP:
$threads = XenForo_Model::create('XenForo_Model_Thread')->getThreads(
array('forum_id' => 32)
);
- Argument 2 passed to XenForo_Model_Thread::getThreads() must be an array, null given, called in ...\library\Wb\Callback\ForumList.php on line 20 and defined in ...\xenforo\library\XenForo\Model\Thread.php, line 500
- Argument 2 passed to XenForo_Model_Thread:repareThreadConditions() must be an array, null given, called in ...\library\XenForo\Model\Thread.php on line 502 and defined in ...\library\XenForo\Model\Thread.php, line 314:
313: </div>
314: <!-- end block: sidebar_online_users -->';
315: $__compilerVar10 .= $__compilerVar11;
- Argument 1 passed to XenForo_Model_Thread:repareThreadFetchOptions() must be an array, null given, called in ...\library\XenForo\Model\Thread.php on line 504 and defined in ...\library\XenForo\Model\Thread.php, line 81:
80: $__compilerVar7 .= '
81: ';
82: foreach ($renderedNodes AS $node)
- Argument 1 passed to XenForo_Model:repareLimitFetchOptions() must be an array, null given, called in ...\library\XenForo\Model\Thread.php on line 505 and defined in ...\library\XenForo\Model.php, line 367:
366: $__compilerVar17 .= '
367: <div class="facebookLike shareControl">
368: ';
Do you know what causes the error? What is the right way to access a model from xen:callback?
Last edited: