summaryrefslogtreecommitdiff
path: root/inc/indexer.php
diff options
context:
space:
mode:
authorMichael Hamann <michael@content-space.de>2011-05-02 15:24:47 +0200
committerMichael Hamann <michael@content-space.de>2011-05-02 15:26:31 +0200
commit952ab260ab7f87aa89066ccc658bfc94ba7f673a (patch)
tree7a12bce4c45c4f1ad397305f2a01f7b5d836fbff /inc/indexer.php
parent4f5cb4d5bc4b7b3b61cdf2d67981eaf514f63060 (diff)
downloadrpg-952ab260ab7f87aa89066ccc658bfc94ba7f673a.tar.gz
rpg-952ab260ab7f87aa89066ccc658bfc94ba7f673a.tar.bz2
Fix a warning in the indexer when words exist without corresponding index FS#2242
Diffstat (limited to 'inc/indexer.php')
-rw-r--r--inc/indexer.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/inc/indexer.php b/inc/indexer.php
index 714feb4f7..d2a38e4a7 100644
--- a/inc/indexer.php
+++ b/inc/indexer.php
@@ -489,6 +489,9 @@ class Doku_Indexer {
foreach ($result as $word => $res) {
$final[$word] = array();
foreach ($res as $wid) {
+ // handle the case when ($ixid < count($index)) has been false
+ // and thus $docs[$wid] hasn't been set.
+ if (!isset($docs[$wid])) continue;
$hits = &$docs[$wid];
foreach ($hits as $hitkey => $hitcnt) {
// make sure the document still exists