From 5c2551d984b51889ac8779fdbcfd70f2123832b2 Mon Sep 17 00:00:00 2001 From: Hendy Date: Sat, 13 Apr 2019 18:34:06 +0100 Subject: [PATCH] startup time fix - ensure index rather than rebuild --- .../Client/Views/Searcher.html | 9 +-------- src/Our.Umbraco.Look/Events/LookIndexing.cs | 4 ++-- 2 files changed, 3 insertions(+), 10 deletions(-) diff --git a/src/Our.Umbraco.Look.BackOffice/Client/Views/Searcher.html b/src/Our.Umbraco.Look.BackOffice/Client/Views/Searcher.html index 2c9c1f1..c6c245a 100644 --- a/src/Our.Umbraco.Look.BackOffice/Client/Views/Searcher.html +++ b/src/Our.Umbraco.Look.BackOffice/Client/Views/Searcher.html @@ -18,18 +18,11 @@
-
Name
-
{{ searcherName }}
- -
Description
-
{{ viewData.searcherDescription }}
-
Type
{{ viewData.searcherType }}
Look Indexing Enabled
-
{{ viewData.lookIndexingEnabled }}
- +
 
diff --git a/src/Our.Umbraco.Look/Events/LookIndexing.cs b/src/Our.Umbraco.Look/Events/LookIndexing.cs index 34b6e95..8146eb0 100644 --- a/src/Our.Umbraco.Look/Events/LookIndexing.cs +++ b/src/Our.Umbraco.Look/Events/LookIndexing.cs @@ -51,9 +51,9 @@ protected override void ApplicationStarted(UmbracoApplicationBase umbracoApplica LookService.Initialize(this._umbracoHelper); - foreach (var lookIndexer in this._lookIndexers.Where(x => !x.IndexExists())) + foreach (var lookIndexer in this._lookIndexers) { - lookIndexer.RebuildIndex(); + lookIndexer.EnsureIndex(false); } ContentService.Published += ContentService_Published;