XF 2.3 Got my first server error!

zzlpolitics

Active member
  • ErrorException: Template error: [E_USER_WARNING] Method canToggleRead is not callable on the given object (XFES\XF\Entity\Thread)
  • src/XF/Template/Templater.php:1278

  • Generated by: 4thgenheel
  • Jul 29, 2024 at 5:43 PM


Stack trace​



#0 [internal function]: XF\Template\Templater->handleTemplateError(512, '[E_USER_WARNING...', 's...', 1278)
#1 src/XF/Template/Templater.php(1278): trigger_error('Method canToggl...', 512)
#2 internal_data/code_cache/templates/l1/s3/public/ozzmodz_tmr_thread_list_macros_button.php(7): XF\Template\Templater->method(Object(XFES\XF\Entity\Thread), 'canToggleRead', Array)
#3 src/XF/Template/Templater.php(1792): XF\Template\Templater->{closure}(Object(XF\Template\Templater), Array, NULL)
#4 src/XF/Template/Templater.php(1866): XF\Template\Templater->renderTemplate('ozzmodz_tmr_thr...', Array)
#5 internal_data/code_cache/templates/l1/s3/public/thread_list_macros.php(444): XF\Template\Templater->includeTemplate('public:ozzmodz_...', Array)
#6 src/XF/Template/Templater.php(1093): XF\Template\Templater->{closure}(Object(XF\Template\Templater), Array, Object(XF\Template\ExtensionSet))
#7 src/XF/Template/Templater.php(1029): XF\Template\Templater->renderExtensionInternal('main_cell', Array, Array, Object(XF\Template\ExtensionSet))
#8 internal_data/code_cache/templates/l1/s3/public/thread_list_macros.php(559): XF\Template\Templater->renderExtension('main_cell', Array, Object(XF\Template\ExtensionSet))
#9 src/XF/Template/Templater.php(922): XF\Template\Templater->{closure}(Object(XF\Template\Templater), Array, Object(XF\Template\ExtensionSet))
#10 internal_data/code_cache/templates/l1/s3/public/forum_view.php(118): XF\Template\Templater->callMacro('thread_list_mac...', 'item', Array, Array)
#11 src/XF/Template/Templater.php(1093): XF\Template\Templater->{closure}(Object(XF\Template\Templater), Array, Object(XF\Template\ExtensionSet))
#12 src/XF/Template/Templater.php(1029): XF\Template\Templater->renderExtensionInternal('thread_list', Array, Array, Object(XF\Template\ExtensionSet))
#13 internal_data/code_cache/templates/l1/s3/public/forum_view.php(574): XF\Template\Templater->renderExtension('thread_list', Array, Object(XF\Template\ExtensionSet))
#14 src/XF/Template/Templater.php(1792): XF\Template\Templater->{closure}(Object(XF\Template\Templater), Array, Object(XF\Template\ExtensionSet))
#15 src/XF/Template/Template.php(24): XF\Template\Templater->renderTemplate('forum_view', Array)
#16 src/XF/Mvc/Renderer/Html.php(50): XF\Template\Template->render()
#17 src/XF/Mvc/Dispatcher.php(471): XF\Mvc\Renderer\Html->renderView('XF:Forum\\View', 'public:forum_vi...', Array)
#18 src/XF/Mvc/Dispatcher.php(453): XF\Mvc\Dispatcher->renderView(Object(XF\Mvc\Renderer\Html), Object(XF\Mvc\Reply\View))
#19 src/XF/Mvc/Dispatcher.php(412): XF\Mvc\Dispatcher->renderReply(Object(XF\Mvc\Renderer\Html), Object(XF\Mvc\Reply\View))
#20 src/XF/Mvc/Dispatcher.php(66): XF\Mvc\Dispatcher->render(Object(XF\Mvc\Reply\View), 'html')
#21 src/XF/App.php(2777): XF\Mvc\Dispatcher->run()
#22 src/XF.php(798): XF\App->run()
#23 index.php(23): XF::runApp('XF\\Pub\\App')
#24 {main}


Request state​



array(4) {
["url"] => string(32) "/forums/politics-other-topics.2/"
["referrer"] => bool(false)
["_GET"] => array(1) {
["/forums/politics-other-topics_2/"] => string(0) ""
}
["_POST"] => array(0) {
}
}

No clue! But, I got the error 42 times and there are 42 threads on the front page and reading through that text I see Mark read so is that function causing me a problem? Any idea how to fix it? I had originally hidden the Mark read/Watch island but actually brought it back by simply delete the code to hide it in extra.less. Did I screw something up there?

Thanks in advance! My first server error!
 
Ahhh. I downloaded and installed a mod that attempted to give you the ability to ignore threads individually but it didn't work so I immediately uninstalled it. Now, thanks to this, I know where to look in the code to see what might be the source of the error.

Thanks so much for your help!
 
Back
Top Bottom