Change "? :" to "?:"
authorKunal Mehta <legoktm@gmail.com>
Thu, 2 Jul 2015 02:15:07 +0000 (19:15 -0700)
committerKunal Mehta <legoktm@gmail.com>
Thu, 2 Jul 2015 02:15:07 +0000 (19:15 -0700)
Anomie pointed out that I am the only person who writes it as "? :", and
that all other instances in core use no space.

Change-Id: I01b68eed5f866fa7582fb4257f795c4c2d1244d1

includes/Title.php
includes/filerepo/file/ArchivedFile.php
includes/specials/SpecialUndelete.php

index 7aa4113..9c8ed47 100644 (file)
@@ -3632,7 +3632,7 @@ class Title {
                        );
                }
 
-               return $errors ? : true;
+               return $errors ?: true;
        }
 
        /**
index 0713a92..1aec446 100644 (file)
@@ -587,6 +587,6 @@ class ArchivedFile {
                $this->load();
 
                $title = $this->getTitle();
-               return Revision::userCanBitfield( $this->deleted, $field, $user, $title ? : null );
+               return Revision::userCanBitfield( $this->deleted, $field, $user, $title ?: null );
        }
 }
index 8a66273..5732ef9 100644 (file)
@@ -757,7 +757,7 @@ class SpecialUndelete extends SpecialPage {
         * @return bool
         */
        protected function isAllowed( $permission, User $user = null ) {
-               $user = $user ? : $this->getUser();
+               $user = $user ?: $this->getUser();
                if ( $this->mTargetObj !== null ) {
                        return $this->mTargetObj->userCan( $permission, $user );
                } else {