summaryrefslogtreecommitdiff
path: root/lib/exe/indexer.php
diff options
context:
space:
mode:
authorAndreas Gohr <andi@splitbrain.org>2005-10-06 19:41:04 +0200
committerAndreas Gohr <andi@splitbrain.org>2005-10-06 19:41:04 +0200
commitbfca19c51ca9fb829f6495014e5daf051e6af8c8 (patch)
tree25d14d54b50988f61a584f94d95cb8f3afd3a848 /lib/exe/indexer.php
parentc73c757e0e421668521e2e4d146aa0f9acac4057 (diff)
downloadrpg-bfca19c51ca9fb829f6495014e5daf051e6af8c8.tar.gz
rpg-bfca19c51ca9fb829f6495014e5daf051e6af8c8.tar.bz2
load indexing include only when needed
darcs-hash:20051006174104-7ad00-4abd8894c1449a46467c0d168e7fc5e90331024c.gz
Diffstat (limited to 'lib/exe/indexer.php')
-rw-r--r--lib/exe/indexer.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/exe/indexer.php b/lib/exe/indexer.php
index 74f0b3924..a81adfeae 100644
--- a/lib/exe/indexer.php
+++ b/lib/exe/indexer.php
@@ -44,7 +44,6 @@ function indexer_stop() {
// Now start work
if(!defined('DOKU_INC')) define('DOKU_INC',realpath(dirname(__FILE__).'/../../').'/');
require_once(DOKU_INC.'inc/init.php');
-require_once(DOKU_INC.'inc/indexer.php');
//close session
session_write_close();
@@ -56,7 +55,6 @@ if(!$ID) indexer_stop();
$last = @filemtime(metaFN($ID,'.indexed'));
if($last > @filemtime(wikiFN($ID))) indexer_stop();
-
// try to aquire a lock
$lock = $conf['lockdir'].'/_indexer.lock';
while(!@mkdir($lock,0777)){
@@ -68,6 +66,8 @@ while(!@mkdir($lock,0777)){
}
}
+require_once(DOKU_INC.'inc/indexer.php');
+
// do the work
idx_addPage($ID);
@@ -79,4 +79,4 @@ indexer_stop();
//Setup VIM: ex: et ts=4 enc=utf-8 :
// No trailing PHP closing tag - no output please!
-// See Note at http://www.php.net/manual/en/language.basic-syntax.instruction-separation.php \ No newline at end of file
+// See Note at http://www.php.net/manual/en/language.basic-syntax.instruction-separation.php