diff options
-rw-r--r-- | inc/fulltext.php | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/inc/fulltext.php b/inc/fulltext.php index 943a5d401..8cdfac42e 100644 --- a/inc/fulltext.php +++ b/inc/fulltext.php @@ -241,6 +241,11 @@ function _ft_pageLookup(&$data){ $pages = array_map('rtrim', idx_getIndex('page', '')); $titles = array_map('rtrim', idx_getIndex('title', '')); + // check for corrupt title index #FS2076 + if(count($pages) != count($titles)){ + $titles = array_fill(0,count($pages),''); + @unlink($conf['indexdir'].'/title.idx'); // will be rebuilt in inc/init.php + } $pages = array_combine($pages, $titles); $cleaned = cleanID($id); |