* @return string
*/
function schemaVersion() {
- return "0.6";
+ return "0.7";
}
/**
$out = " <revision>\n";
$out .= " " . Xml::element( 'id', null, strval( $row->rev_id ) ) . "\n";
+ if( $row->rev_parent_id ) {
+ $out .= " " . Xml::element( 'parentid', null, strval( $row->rev_parent_id ) ) . "\n";
+ }
$out .= $this->writeTimestamp( $row->rev_timestamp );
* @return string
*/
function writeUploads( $row, $dumpContents = false ) {
- if ( $row->page_namespace == NS_IMAGE ) {
+ if ( $row->page_namespace == NS_FILE ) {
$img = wfLocalFile( $row->page_title );
if ( $img && $img->exists() ) {
$out = '';
} else {
$contents = '';
}
+ if ( $file->isDeleted( File::DELETED_COMMENT ) ) {
+ $comment = Xml::element( 'comment', array( 'deleted' => 'deleted' ) );
+ } else {
+ $comment = Xml::elementClean( 'comment', null, $file->getDescription() );
+ }
return " <upload>\n" .
$this->writeTimestamp( $file->getTimestamp() ) .
$this->writeContributor( $file->getUser( 'id' ), $file->getUser( 'text' ) ) .
- " " . Xml::elementClean( 'comment', null, $file->getDescription() ) . "\n" .
+ " " . $comment . "\n" .
" " . Xml::element( 'filename', null, $file->getName() ) . "\n" .
$archiveName .
" " . Xml::element( 'src', null, $file->getCanonicalUrl() ) . "\n" .