File tree Expand file tree Collapse file tree
Classes/Flowpack/SearchPlugin/Controller Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2020class SuggestController extends ActionController
2121{
2222 /**
23- * @Flow\Inject
23+ * Dynamic dependency; to make the system work with SimpleSearch
2424 * @var \Flowpack\ElasticSearch\ContentRepositoryAdaptor\ElasticSearchClient
2525 */
2626 protected $ elasticSearchClient ;
@@ -32,6 +32,13 @@ class SuggestController extends ActionController
3232 'json ' => 'TYPO3\Flow\Mvc\View\JsonView '
3333 ];
3434
35+ public function initializeObject ()
36+ {
37+ if ($ this ->objectManager ->isRegistered ('Flowpack\ElasticSearch\ContentRepositoryAdaptor\ElasticSearchClient ' )) {
38+ $ this ->elasticSearchClient = $ this ->objectManager ->get ('Flowpack\ElasticSearch\ContentRepositoryAdaptor\ElasticSearchClient ' );
39+ }
40+ }
41+
3542 /**
3643 * @param string $term
3744 * @return void
You can’t perform that action at this time.
0 commit comments