From 74fa4635cab8c99a069b395a273529af43abc8c1 Mon Sep 17 00:00:00 2001 From: Platonides Date: Mon, 28 May 2012 19:37:35 +0200 Subject: [PATCH] Change if/else to a ternary operator This keep the wfProfileOut() detector happy. Change-Id: I85ecc33121d94e6a2d2e8ea3d1f5ca47f3db86bc --- includes/WikiPage.php | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/includes/WikiPage.php b/includes/WikiPage.php index fffd5f644e..b5318c0a1a 100644 --- a/includes/WikiPage.php +++ b/includes/WikiPage.php @@ -530,11 +530,7 @@ class WikiPage extends Page { } wfProfileOut( __METHOD__ ); - if ( $row ) { - return Revision::newFromRow( $row ); - } else { - return null; - } + return $row ? Revision::newFromRow( $row ) : null; } /** -- 2.20.1