- Affected version
- XFES 2.3.2
I have XF 2.3.2, XFES 2.3.2, ES 7.17.18
Enabled search option,
Deleted and rebuild search index.
Yet, when searching, it does not auto complete.
Disabled all addons and issue still persists.
Here is the error log which leads me to this post.
Enable dynamic avatars option and the auto completion feature works.
#1 src/XF/Template/Templater.php(2409): XF\Template\Templater->getDynamicAvatarHtml('AndyWangBreak', 'avatar-u52773-s', Array)
#2 src/XF/Template/Templater.php(1220): XF\Template\Templater->fnAvatar(Object(XF\Template\Templater), false, Object(XFRM\XF\Entity\User), 'xxs', false, Array)
#3 src/XF/Search/Data/AutoCompletableTrait.php(43): XF\Template\Templater->func('avatar', Array)
#4 src/XF/Search/Data/Thread.php(108): XF\Search\Data\Thread->getSimpleAutoCompleteResult('Level 1 HW from...', '/threads/level-...', 'Hi Apalley!
Th...', Object(XFRM\XF\Entity\User))
#5 src/XF/Search/Search.php(299): XF\Search\Data\Thread->getAutoCompleteResult(Object(XFMG\XF\Entity\Thread), Array)
#6 src/XF/ResultSet.php(129): XF\Search\Search->XF\Search\{closure}(Object(XFMG\XF\Entity\Thread), 'thread', 58035)
#7 src/XF/Search/Search.php(285): XF\ResultSet->getResultsDataCallback(Object(Closure))
#8 src/XF/Pub/Controller/SearchController.php(123): XF\Search\Search->getAutoCompleteResults(Object(XF\ResultSet), Array)
#9 src/XF/Mvc/Dispatcher.php(362): XF\Pub\Controller\SearchController->actionAutoComplete(Object(XF\Mvc\ParameterBag))
#10 src/XF/Mvc/Dispatcher.php(264): XF\Mvc\Dispatcher->dispatchClass('XF:Search', 'AutoComplete', Object(XF\Mvc\RouteMatch), Object(XFES\XF\Pub\Controller\Search), NULL)
#11 src/XF/Mvc/Dispatcher.php(121): XF\Mvc\Dispatcher->dispatchFromMatch(Object(XF\Mvc\RouteMatch), Object(XFES\XF\Pub\Controller\Search), NULL)
#12 src/XF/Mvc/Dispatcher.php(63): XF\Mvc\Dispatcher->dispatchLoop(Object(XF\Mvc\RouteMatch))
#13 src/XF/App.php(2813): XF\Mvc\Dispatcher->run()
#14 src/XF.php(802): XF\App->run()
#15 index.php(23): XF::runApp('XF\\Pub\\App')
#16 {main}
["url"] => string(21) "/search/auto-complete"
["referrer"] => string(28) "https://xxxx.com/resources/"
["_GET"] => array(1) {
["/search/auto-complete"] => string(0) ""
}
["_POST"] => array(7) {
["keywords"] => string(4) "andy"
["constraints"] => string(0) ""
["c"] => array(1) {
["users"] => string(0) ""
}
["_xfToken"] => string(8) "********"
["_xfResponseType"] => string(4) "json"
["_xfWithData"] => string(1) "1"
["_xfRequestUri"] => string(11) "/resources/"
}
}
Enabled search option,
Deleted and rebuild search index.
Yet, when searching, it does not auto complete.
Disabled all addons and issue still persists.
Here is the error log which leads me to this post.
Enable dynamic avatars option and the auto completion feature works.
- Error: Call to a member function getProperty() on null
- src/XF/Template/Templater.php:2570
- 8/25/24 at 11:56 AM
Stack trace
#0 src/XF/Template/Templater.php(2462): XF\Template\Templater->getFallbackAvatarHtml('avatar-u52773-s', Array)#1 src/XF/Template/Templater.php(2409): XF\Template\Templater->getDynamicAvatarHtml('AndyWangBreak', 'avatar-u52773-s', Array)
#2 src/XF/Template/Templater.php(1220): XF\Template\Templater->fnAvatar(Object(XF\Template\Templater), false, Object(XFRM\XF\Entity\User), 'xxs', false, Array)
#3 src/XF/Search/Data/AutoCompletableTrait.php(43): XF\Template\Templater->func('avatar', Array)
#4 src/XF/Search/Data/Thread.php(108): XF\Search\Data\Thread->getSimpleAutoCompleteResult('Level 1 HW from...', '/threads/level-...', 'Hi Apalley!
Th...', Object(XFRM\XF\Entity\User))
#5 src/XF/Search/Search.php(299): XF\Search\Data\Thread->getAutoCompleteResult(Object(XFMG\XF\Entity\Thread), Array)
#6 src/XF/ResultSet.php(129): XF\Search\Search->XF\Search\{closure}(Object(XFMG\XF\Entity\Thread), 'thread', 58035)
#7 src/XF/Search/Search.php(285): XF\ResultSet->getResultsDataCallback(Object(Closure))
#8 src/XF/Pub/Controller/SearchController.php(123): XF\Search\Search->getAutoCompleteResults(Object(XF\ResultSet), Array)
#9 src/XF/Mvc/Dispatcher.php(362): XF\Pub\Controller\SearchController->actionAutoComplete(Object(XF\Mvc\ParameterBag))
#10 src/XF/Mvc/Dispatcher.php(264): XF\Mvc\Dispatcher->dispatchClass('XF:Search', 'AutoComplete', Object(XF\Mvc\RouteMatch), Object(XFES\XF\Pub\Controller\Search), NULL)
#11 src/XF/Mvc/Dispatcher.php(121): XF\Mvc\Dispatcher->dispatchFromMatch(Object(XF\Mvc\RouteMatch), Object(XFES\XF\Pub\Controller\Search), NULL)
#12 src/XF/Mvc/Dispatcher.php(63): XF\Mvc\Dispatcher->dispatchLoop(Object(XF\Mvc\RouteMatch))
#13 src/XF/App.php(2813): XF\Mvc\Dispatcher->run()
#14 src/XF.php(802): XF\App->run()
#15 index.php(23): XF::runApp('XF\\Pub\\App')
#16 {main}
Request state
array(4) {["url"] => string(21) "/search/auto-complete"
["referrer"] => string(28) "https://xxxx.com/resources/"
["_GET"] => array(1) {
["/search/auto-complete"] => string(0) ""
}
["_POST"] => array(7) {
["keywords"] => string(4) "andy"
["constraints"] => string(0) ""
["c"] => array(1) {
["users"] => string(0) ""
}
["_xfToken"] => string(8) "********"
["_xfResponseType"] => string(4) "json"
["_xfWithData"] => string(1) "1"
["_xfRequestUri"] => string(11) "/resources/"
}
}