|
57 | 57 |
|
58 | 58 | import com.github.bsideup.jabel.Desugar; |
59 | 59 | import com.hfstudio.guidenh.guide.Guide; |
60 | | -import com.hfstudio.guidenh.guide.Guides; |
61 | 60 | import com.hfstudio.guidenh.guide.compiler.IndexingSink; |
62 | 61 | import com.hfstudio.guidenh.guide.compiler.ParsedGuidePage; |
63 | 62 | import com.hfstudio.guidenh.guide.document.flow.LytFlowContent; |
| 63 | +import com.hfstudio.guidenh.guide.internal.GuideRegistry; |
64 | 64 | import com.hfstudio.guidenh.guide.internal.util.LangUtil; |
65 | 65 | import com.hfstudio.guidenh.guide.mediawiki.MediaWikiPageIds; |
66 | 66 | import com.hfstudio.guidenh.guide.mediawiki.MediaWikiPageTitleResolver; |
@@ -144,7 +144,7 @@ public void index(Guide guide) { |
144 | 144 | } |
145 | 145 |
|
146 | 146 | public void indexAll() { |
147 | | - String fingerprint = fingerprint(Guides.getAll()); |
| 147 | + String fingerprint = fingerprint(GuideRegistry.getAll()); |
148 | 148 | cancelPendingWork(); |
149 | 149 | indexedLanguages.clear(); |
150 | 150 | warnedAboutLanguage.clear(); |
@@ -176,7 +176,7 @@ public void indexAll() { |
176 | 176 | throw new UncheckedIOException("Failed to reset the guide search index.", e); |
177 | 177 | } |
178 | 178 |
|
179 | | - for (var guide : Guides.getAll()) { |
| 179 | + for (var guide : GuideRegistry.getAll()) { |
180 | 180 | index(guide); |
181 | 181 | } |
182 | 182 | } |
@@ -368,7 +368,7 @@ public List<SearchResult> searchGuide(String queryText, @Nullable Guide onlyFrom |
368 | 368 | var guideId = new ResourceLocation(document.get(IndexSchema.FIELD_GUIDE_ID)); |
369 | 369 | var pageId = new ResourceLocation(document.get(IndexSchema.FIELD_PAGE_ID)); |
370 | 370 |
|
371 | | - var guide = Guides.getById(guideId); |
| 371 | + var guide = GuideRegistry.getById(guideId); |
372 | 372 | if (guide == null) { |
373 | 373 | GuideDebugLog.warn( |
374 | 374 | "[GuideNH] [GuideSearch] Search index produced guide id {} which couldn't be found.", |
|
0 commit comments