r107586 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r107585‎ | r107586 | r107587 >
Date:18:51, 29 December 2011
Author:ialex
Status:ok
Tags:
Comment:
Use WikiPage instead of Article to call doEdit()
Modified paths:
  • /trunk/phase3/maintenance/edit.php (modified) (history)

Diff [purge]

Index: trunk/phase3/maintenance/edit.php
@@ -58,14 +58,14 @@
5959 $this->error( "Invalid title", true );
6060 }
6161
62 - $article = new Article( $wgTitle );
 62+ $page = WikiPage::factory( $wgTitle );
6363
6464 # Read the text
6565 $text = $this->getStdin( Maintenance::STDIN_ALL );
6666
6767 # Do the edit
6868 $this->output( "Saving... " );
69 - $status = $article->doEdit( $text, $summary,
 69+ $status = $page->doEdit( $text, $summary,
7070 ( $minor ? EDIT_MINOR : 0 ) |
7171 ( $bot ? EDIT_FORCE_BOT : 0 ) |
7272 ( $autoSummary ? EDIT_AUTOSUMMARY : 0 ) |

Status & tagging log