r38274 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r38273‎ | r38274 | r38275 >
Date:02:44, 31 July 2008
Author:demon
Status:old
Tags:
Comment:
I honestly have no clue how this got committed; wasn't even using subversion. I really need some sleep it seems.
Modified paths:
  • /trunk/phase3/includes/Article.php (modified) (history)
  • /trunk/phase3/includes/EditPage.php (modified) (history)
  • /trunk/phase3/languages/messages/MessagesEn.php (modified) (history)
  • /trunk/phase3/maintenance/archives/patch-rd_fragment.sql (deleted) (history)
  • /trunk/phase3/maintenance/archives/patch-rd_interwiki.sql (deleted) (history)
  • /trunk/phase3/maintenance/tables.sql (modified) (history)
  • /trunk/phase3/maintenance/updaters.inc (modified) (history)

Diff [purge]

Index: trunk/phase3/maintenance/archives/patch-rd_fragment.sql
@@ -1,4 +0,0 @@
2 -
3 -ALTER TABLE /*$wgDBprefix*/redirect
4 - ADD rd_fragment varchar(255) binary DEFAULT NULL;
\ No newline at end of file
Index: trunk/phase3/maintenance/archives/patch-rd_interwiki.sql
@@ -1,4 +0,0 @@
2 -
3 -ALTER TABLE /*$wgDBprefix*/redirect
4 - ADD rd_interwiki varchar(32) default NULL;
\ No newline at end of file
Index: trunk/phase3/maintenance/updaters.inc
@@ -143,10 +143,6 @@
144144 array( 'maybe_do_profiling_memory_update' ),
145145 array( 'do_filearchive_indices_update' ),
146146 array( 'update_password_format' ),
147 -
148 - // 1.14
149 - array( 'add_field', 'redirect', 'rd_interwiki', 'patch-rd_interwiki.sql' ),
150 - array( 'add_field', 'redirect', 'rd_fragment', 'patch-rd_fragment.sql' ),
151147 );
152148
153149
@@ -1720,4 +1716,3 @@
17211717 return;
17221718 }
17231719
1724 -
Index: trunk/phase3/maintenance/tables.sql
@@ -1157,8 +1157,6 @@
11581158 -- goes by.
11591159 rd_namespace int NOT NULL default '0',
11601160 rd_title varchar(255) binary NOT NULL default '',
1161 - rd_interwiki varchar(32) default NULL,
1162 - rd_fragment varchar(255) binary DEFAULT NULL,
11631161
11641162 PRIMARY KEY rd_from (rd_from),
11651163 KEY rd_ns_title (rd_namespace,rd_title,rd_from)
Index: trunk/phase3/includes/Article.php
@@ -103,9 +103,7 @@
104104 $dbw->replace('redirect', array('rd_from'), array(
105105 'rd_from' => $this->getID(),
106106 'rd_namespace' => $retval->getNamespace(),
107 - 'rd_title' => $retval->getDBKey(),
108 - 'rd_interwiki' => $retval->getInterwiki(),
109 - 'rd_fragment' => $retval->getFragment(),
 107+ 'rd_title' => $retval->getDBKey()
110108 ), __METHOD__);
111109 return $retval;
112110 }
@@ -1184,8 +1182,6 @@
11851183 'rd_namespace' => $redirectTitle->getNamespace(),
11861184 'rd_title' => $redirectTitle->getDBkey(),
11871185 'rd_from' => $this->getId(),
1188 - 'rd_interwiki' => $redirectTitle->getInterwiki(),
1189 - 'rd_fragment' => $redirectTitle->getFragment(),
11901186 );
11911187
11921188 $dbw->replace( 'redirect', array( 'rd_from' ), $set, __METHOD__ );
Index: trunk/phase3/includes/EditPage.php
@@ -41,7 +41,6 @@
4242 const AS_SPAM_ERROR = 232;
4343 const AS_IMAGE_REDIRECT_ANON = 233;
4444 const AS_IMAGE_REDIRECT_LOGGED = 234;
45 - const AS_DOUBLE_REDIRECT = 235;
4645
4746 var $mArticle;
4847 var $mTitle;
@@ -59,7 +58,6 @@
6059 var $kblength = false;
6160 var $missingComment = false;
6261 var $missingSummary = false;
63 - var $doubleRedirect = false;
6462 var $allowBlankSummary = false;
6563 var $autoSumm = '';
6664 var $hookError = '';
@@ -929,11 +927,6 @@
930928 return self::AS_HOOK_ERROR;
931929 }
932930
933 - # Are we creating a double redirect?
934 - if ( $redirectTitle = Title::newFromRedirect( $this->textbox1 ) && $redirectTitle->isRedirect() ) {
935 - $this->doubleRedirect = $redirectTitle;
936 - }
937 -
938931 # Handle the user preference to force summaries here, but not for null edits
939932 if( $this->section != 'new' && !$this->allowBlankSummary && $wgUser->getOption( 'forceeditsummary') &&
940933 0 != strcmp($oldtext, $text) &&
@@ -1094,11 +1087,6 @@
10951088 $wgOut->wrapWikiMsg( '<div id="mw-missingcommenttext">$1</div>', 'missingcommenttext' );
10961089 }
10971090
1098 - if ( $this->doubleRedirect instanceof Title ) {
1099 - $wgOut->wrapWikiMsg( '<div id="mw-creatingdoubleredirect">$1</div>',
1100 - array( 'creatingdoubleredirect', $this->mTitle->getText(), $this->doubleRedirect->getText() ) );
1101 - }
1102 -
11031091 if( $this->missingSummary && $this->section != 'new' ) {
11041092 $wgOut->wrapWikiMsg( '<div id="mw-missingsummary">$1</div>', 'missingsummary' );
11051093 }
@@ -1373,9 +1361,6 @@
13741362 // mode will show an extra newline. A bit annoying.
13751363 $encodedtext .= "\n";
13761364 }
1377 - if ( $this->doubleRedirect instanceof Title ) {
1378 - $wgOut->addHTML( Xml::hidden( 'wpIgnoreDoubleRedirect', true ) );
1379 - }
13801365
13811366 $wgOut->addHTML( <<<END
13821367 $recreate
Index: trunk/phase3/languages/messages/MessagesEn.php
@@ -1034,8 +1034,6 @@
10351035 'missingcommenttext' => 'Please enter a comment below.',
10361036 'missingcommentheader' => "'''Reminder:''' You have not provided a subject/headline for this comment.
10371037 If you click Save again, your edit will be saved without one.",
1038 -'creatingdoubleredirect' => "'''Caution:''' You are attempting to redirect this page to [[$1]], but it redirects to
1039 -[[$2]]. Redirects that redirect two or more times do not work.",
10401038 'summary-preview' => 'Summary preview',
10411039 'subject-preview' => 'Subject/headline preview',
10421040 'blockedtitle' => 'User is blocked',

Status & tagging log