From 74b952213495f7044d05afe1dd3de9c0b06e44ef Mon Sep 17 00:00:00 2001 From: Alexandre Emsenhuber Date: Wed, 21 Dec 2011 18:53:00 +0000 Subject: [PATCH] Declare constant default values directly in the class definition and removed the constructor since it's useless now --- includes/cache/LinkCache.php | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/includes/cache/LinkCache.php b/includes/cache/LinkCache.php index 785b19b3b1..a73eaaa4a3 100644 --- a/includes/cache/LinkCache.php +++ b/includes/cache/LinkCache.php @@ -9,8 +9,10 @@ class LinkCache { // becomes incompatible with the new version. private $mClassVer = 4; - private $mGoodLinks, $mBadLinks; - private $mForUpdate; + private $mGoodLinks = array(); + private $mGoodLinkFields = array(); + private $mBadLinks = array(); + private $mForUpdate = false; /** * Get an instance of this class @@ -25,13 +27,6 @@ class LinkCache { return $instance; } - function __construct() { - $this->mForUpdate = false; - $this->mGoodLinks = array(); - $this->mGoodLinkFields = array(); - $this->mBadLinks = array(); - } - /** * General accessor to get/set whether SELECT FOR UPDATE should be used * -- 2.20.1