Index: trunk/phase3/includes/EditPage.php |
— | — | @@ -918,10 +918,8 @@ |
919 | 919 | if ( is_null( $text ) ) { |
920 | 920 | wfDebug( "EditPage::editForm activating conflict; section replace failed.\n" ); |
921 | 921 | $this->isConflict = true; |
922 | | - $text = $this->textbox1; |
923 | | - } |
924 | | - |
925 | | - if ( $this->isConflict ) { |
| 922 | + $text = $this->textbox1; // do not try to merge here! |
| 923 | + } else if ( $this->isConflict ) { |
926 | 924 | # Attempt merge |
927 | 925 | if ( $this->mergeChangesInto( $text ) ) { |
928 | 926 | // Successful merge! Maybe we should tell the user the good news? |
— | — | @@ -1149,9 +1147,7 @@ |
1150 | 1148 | if ( $this->section != '' && $this->section != 'new' ) { |
1151 | 1149 | $matches = array(); |
1152 | 1150 | if ( !$this->summary && !$this->preview && !$this->diff ) { |
1153 | | - preg_match( "/^(=+)(.+)\\1/mi", |
1154 | | - $this->textbox1, |
1155 | | - $matches ); |
| 1151 | + preg_match( "/^(=+)(.+)\\1/mi", $this->textbox1, $matches ); |
1156 | 1152 | if ( !empty( $matches[2] ) ) { |
1157 | 1153 | global $wgParser; |
1158 | 1154 | $this->summary = "/* " . |
— | — | @@ -1842,8 +1838,7 @@ |
1843 | 1839 | $baseText = $baseRevision->getText(); |
1844 | 1840 | |
1845 | 1841 | // The current state, we want to merge updates into it |
1846 | | - $currentRevision = Revision::loadFromTitle( |
1847 | | - $db, $this->mTitle ); |
| 1842 | + $currentRevision = Revision::loadFromTitle( $db, $this->mTitle ); |
1848 | 1843 | if ( is_null( $currentRevision ) ) { |
1849 | 1844 | wfProfileOut( $fname ); |
1850 | 1845 | return false; |