Wikia code/includes/specials/SpecialImport.php
This page is obsolete. It is being retained for archival purposes. It may document extensions or features that are obsolete and/or no longer supported. Do not rely on the information here being up-to-date. The information shown below refers to the now unmaintained 1.16 MediaWiki release. The current stable release number is 1.42.1. |
--- D:\Programming\SVN\mediawiki\branches\REL1_16\phase3\includes\specials\SpecialImport.php 2011-07-18 22:31:17.649414100 +0100
+++ D:\Programming\SVN\wikia\trunk\includes\specials\SpecialImport.php 2011-08-17 15:28:16.292968700 +0100
@@ -138,6 +138,16 @@
}
$reporter = new ImportReporter( $importer, $isUpload, $this->interwiki , $this->logcomment);
+ /* wikia change begin - author: uberfuzzy */
+ /* if var=true (not empty)-> turn off irc feed, so imports dont go to feed
+ if var=false (empty)-> no touch, use what ever was already */
+ global $wgWikiaHideImportsFromIrc;
+ if( !empty($wgWikiaHideImportsFromIrc) ) {
+ global $wgRC2UDPEnabled;
+ $wgRC2UDPEnabled = false;
+ }
+ /* end wikia change */
+
$reporter->open();
$result = $importer->doImport();
$resultCount = $reporter->close();
@@ -350,11 +360,13 @@
$dbw = wfGetDB( DB_MASTER );
$latest = $title->getLatestRevID();
$nullRevision = Revision::newNullRevision( $dbw, $title->getArticleId(), $comment, true );
+ if (!is_null($nullRevision)) {
$nullRevision->insertOn( $dbw );
$article = new Article( $title );
# Update page record
$article->updateRevisionOn( $dbw, $nullRevision );
wfRunHooks( 'NewRevisionFromEditComplete', array($article, $nullRevision, $latest, $wgUser) );
+ }
} else {
$wgOut->addHTML( "<li>" . $skin->linkKnown( $title ) . " " .
wfMsgHtml( 'import-nonewrevisions' ) . "</li>\n" );