From cecb985bee3bdd252e1b8dc0bd500b37cd52be01 Mon Sep 17 00:00:00 2001 From: Pierre Schmitz Date: Wed, 16 May 2007 20:58:53 +0000 Subject: Aktualisierung auf MediaWiki 1.10.0 Plugins angepasst und verbessert kleine Korrekturen am Design --- maintenance/importLogs.inc | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'maintenance/importLogs.inc') diff --git a/maintenance/importLogs.inc b/maintenance/importLogs.inc index 154657c8..0dc87eab 100644 --- a/maintenance/importLogs.inc +++ b/maintenance/importLogs.inc @@ -23,8 +23,7 @@ * Not yet complete. * * @todo document - * @package MediaWiki - * @subpackage Maintenance + * @addtogroup Maintenance */ /** */ @@ -36,15 +35,14 @@ require_once( 'LogPage.php' ); /** * Log importer * @todo document - * @package MediaWiki - * @subpackage Maintenance + * @addtogroup Maintenance */ class LogImporter { var $dummy = false; function LogImporter( $type ) { $this->type = $type; - $this->db =& wfGetDB( DB_MASTER ); + $this->db = wfGetDB( DB_MASTER ); $this->actions = $this->setupActions(); } @@ -77,6 +75,7 @@ class LogImporter { } $lines = explode( '
  • ', $text ); foreach( $lines as $line ) { + $matches = array(); if( preg_match( '!^(.*)
  • !', $line, $matches ) ) { $this->importLine( $matches[1] ); } @@ -88,6 +87,7 @@ class LogImporter { # 01:55, 23 Aug 2004 - won't take in strtotimr # "Aug 23 2004 01:55" - seems ok # TODO: multilingual attempt to extract from the data in Language + $matches = array(); if( preg_match( '/^(\d+:\d+(?::\d+)?), (.*)$/', $date, $matches ) ) { $date = $matches[2] . ' ' . $matches[1]; } @@ -99,6 +99,7 @@ class LogImporter { function importLine( $line ) { foreach( $this->actions as $action => $regexp ) { + $matches = array(); if( preg_match( $regexp, $line, $matches ) ) { if( $this->dummy ) { #var_dump( $matches ); -- cgit v1.2.2