mirror of
https://github.com/silverstripe/silverstripe-fulltextsearch
synced 2024-10-22 14:05:29 +02:00
Merge pull request #273 from adrexia/fix/queuedreindex
FIX: allow update processor to be overridden by existing yml
This commit is contained in:
commit
4be5de76a5
@ -11,7 +11,8 @@ use SilverStripe\ORM\DB;
|
|||||||
use SilverStripe\FullTextSearch\Search\FullTextSearch;
|
use SilverStripe\FullTextSearch\Search\FullTextSearch;
|
||||||
use SilverStripe\FullTextSearch\Search\SearchIntrospection;
|
use SilverStripe\FullTextSearch\Search\SearchIntrospection;
|
||||||
use SilverStripe\FullTextSearch\Search\Variants\SearchVariant;
|
use SilverStripe\FullTextSearch\Search\Variants\SearchVariant;
|
||||||
use SilverStripe\FullTextSearch\Search\Processors\SearchUpdateImmediateProcessor;
|
use SilverStripe\FullTextSearch\Search\Processors\SearchUpdateProcessor;
|
||||||
|
|
||||||
use ReflectionClass;
|
use ReflectionClass;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -151,7 +152,7 @@ class SearchUpdater
|
|||||||
foreach ($dirtyids as $dirtyclass => $ids) {
|
foreach ($dirtyids as $dirtyclass => $ids) {
|
||||||
if ($ids) {
|
if ($ids) {
|
||||||
if (!self::$processor) {
|
if (!self::$processor) {
|
||||||
self::$processor = Injector::inst()->create(SearchUpdateImmediateProcessor::class);
|
self::$processor = Injector::inst()->create(SearchUpdateProcessor::class);
|
||||||
}
|
}
|
||||||
self::$processor->addDirtyIDs($dirtyclass, $ids, $index);
|
self::$processor->addDirtyIDs($dirtyclass, $ids, $index);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user