You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
wiki/backend/tasks/simple/rebuild-search-index.ts

10 lines
298 B

/**
* Recompute the search vector of every page.
*
* Queued from the admin area's search view, and safe to run at any time: it only rewrites `pages.ts`
* from the content already stored on each page.
*/
export async function task(): Promise<void> {
await WIKI.models.search.rebuildIndex()
}