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
Merge "Display "Printable version" links in toolbox on special pages"
[lhc/web/wiklou.git]
/
includes
/
api
/
ApiImport.php
diff --git
a/includes/api/ApiImport.php
b/includes/api/ApiImport.php
index
1f0a5fa
..
f48a822
100644
(file)
--- a/
includes/api/ApiImport.php
+++ b/
includes/api/ApiImport.php
@@
-57,7
+57,7
@@
class ApiImport extends ApiBase {
$source = ImportStreamSource::newFromUpload( 'xml' );
}
if ( !$source->isOK() ) {
$source = ImportStreamSource::newFromUpload( 'xml' );
}
if ( !$source->isOK() ) {
- $this->die
UsageMsg( $source->getErrorsArray()
);
+ $this->die
Status( $source
);
}
$importer = new WikiImporter( $source->value );
}
$importer = new WikiImporter( $source->value );
@@
-66,8
+66,8
@@
class ApiImport extends ApiBase {
}
if ( isset( $params['rootpage'] ) ) {
$statusRootPage = $importer->setTargetRootPage( $params['rootpage'] );
}
if ( isset( $params['rootpage'] ) ) {
$statusRootPage = $importer->setTargetRootPage( $params['rootpage'] );
- if( !$statusRootPage->isGood() ) {
- $this->die
UsageMsg( $statusRootPage->getErrorsArray()
);
+ if
( !$statusRootPage->isGood() ) {
+ $this->die
Status( $statusRootPage
);
}
}
$reporter = new ApiImportReporter(
}
}
$reporter = new ApiImportReporter(