r107204 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r107203‎ | r107204 | r107205 >
Date:15:32, 24 December 2011
Author:ialex
Status:ok (Comments)
Tags:
Comment:
Per Nikerabbit, follow-up r102024: removed uneeded variable
Modified paths:
  • /trunk/phase3/includes/EditPage.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/EditPage.php
@@ -371,7 +371,7 @@
372372 # Use the normal message if there's nothing to display
373373 if ( $this->firsttime && $content === '' ) {
374374 $action = $this->mTitle->exists() ? 'edit' :
375 - ( $permission = $this->mTitle->isTalkPage() ? 'createtalk' : 'createpage' );
 375+ ( $this->mTitle->isTalkPage() ? 'createtalk' : 'createpage' );
376376 throw new PermissionsError( $action, $permErrors );
377377 }
378378

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r102024Some cleanup to EditPage:...ialex18:35, 4 November 2011

Comments

#Comment by 😂 (talk | contribs)   15:43, 24 December 2011

Why not ditch the ternary entirely? Nested ternaries are hard to read.

#Comment by Nikerabbit (talk | contribs)   10:29, 25 December 2011

I agree.

Status & tagging log