dépôts
/
lhc
/
web
/
wiklou.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Don't check namespace in SpecialWantedtemplates
[lhc/web/wiklou.git]
/
maintenance
/
importDump.php
diff --git
a/maintenance/importDump.php
b/maintenance/importDump.php
index
1fedefb
..
ea8c84b
100644
(file)
--- a/
maintenance/importDump.php
+++ b/
maintenance/importDump.php
@@
-141,8
+141,7
@@
TEXT;
} elseif ( $obj instanceof WikiRevision ) {
$ns = $obj->title->getNamespace();
} else {
} elseif ( $obj instanceof WikiRevision ) {
$ns = $obj->title->getNamespace();
} else {
- echo wfBacktrace();
- $this->error( "Cannot get namespace of object in " . __METHOD__, true );
+ throw new MWException( "Cannot get namespace of object in " . __METHOD__ );
}
return is_array( $this->nsFilter ) && !in_array( $ns, $this->nsFilter );
}
return is_array( $this->nsFilter ) && !in_array( $ns, $this->nsFilter );
@@
-271,7
+270,7
@@
TEXT;
$this->startTime = microtime( true );
$source = new ImportStreamSource( $handle );
$this->startTime = microtime( true );
$source = new ImportStreamSource( $handle );
- $importer = new WikiImporter( $source );
+ $importer = new WikiImporter( $source
, $this->getConfig()
);
if ( $this->hasOption( 'debug' ) ) {
$importer->setDebug( true );
if ( $this->hasOption( 'debug' ) ) {
$importer->setDebug( true );