From 647f1265251e9e1026bfe46d2d008a48248b05d0 Mon Sep 17 00:00:00 2001 From: Chad Horohoe Date: Thu, 4 Jun 2009 01:10:06 +0000 Subject: [PATCH] (bug 11654) updateSearchIndex.php now uses a wiki-specific position file. --- maintenance/updateSearchIndex.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/maintenance/updateSearchIndex.php b/maintenance/updateSearchIndex.php index f51617bb5f..571e65fe3b 100644 --- a/maintenance/updateSearchIndex.php +++ b/maintenance/updateSearchIndex.php @@ -22,7 +22,7 @@ require_once( 'updateSearchIndex.inc' ); if ( isset( $options['p'] ) ) { $posFile = $options['p']; } else { - $posFile = 'searchUpdate.pos'; + $posFile = 'searchUpdate.' . wfWikiId() . '.pos'; } if ( isset( $options['e'] ) ) { @@ -33,6 +33,11 @@ if ( isset( $options['e'] ) ) { if ( isset( $options['s'] ) ) { $start = $options['s']; +elseif( is_readable( 'searchUpdate.pos' ) ) { + # B/c to the old position file name which was hardcoded + # We can safely delete the file when we're done though. + $start = file_get_contents( 'searchUpdate.pos' ); + unlink( 'searchUpdate.pos' ); } else { $start = @file_get_contents( $posFile ); if ( !$start ) { -- 2.20.1