mirror of
https://github.com/silverstripe/silverstripe-cms
synced 2024-10-22 08:05:56 +02:00
Merge pull request #1181 from dhensby/pulls/injector-searc-form
FIX Use SearchForm::create to instantiate SearchForm
This commit is contained in:
commit
221281dade
@ -27,7 +27,7 @@ class ContentControllerSearchExtension extends Extension {
|
|||||||
$actions = new FieldList(
|
$actions = new FieldList(
|
||||||
new FormAction('results', _t('SearchForm.GO', 'Go'))
|
new FormAction('results', _t('SearchForm.GO', 'Go'))
|
||||||
);
|
);
|
||||||
$form = new SearchForm($this->owner, 'SearchForm', $fields, $actions);
|
$form = SearchForm::create($this->owner, 'SearchForm', $fields, $actions);
|
||||||
$form->classesToSearch(FulltextSearchable::get_searchable_classes());
|
$form->classesToSearch(FulltextSearchable::get_searchable_classes());
|
||||||
return $form;
|
return $form;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user