From: Brion Vibber Date: Fri, 23 Dec 2005 01:27:27 +0000 (+0000) Subject: * Fix autoconfirm check for old accounts X-Git-Tag: 1.6.0~896 X-Git-Url: https://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/banques/?a=commitdiff_plain;h=6ca65246643875ad1cd2a4d2df8a91a8faaf5250;p=lhc%2Fweb%2Fwiklou.git * Fix autoconfirm check for old accounts --- diff --git a/RELEASE-NOTES b/RELEASE-NOTES index c481ca3fb1..bbe169d911 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -346,6 +346,7 @@ fully support the editing toolbar, but was found to be too confusing. * User::isNewbie now uses the registration date and $wgAutoconfirmAge * Log views show message when no matches * Fix raw sitenotice display on database error +* Fix autoconfirm check for old accounts === Caveats === diff --git a/includes/User.php b/includes/User.php index 17fef75a75..07a11b3344 100644 --- a/includes/User.php +++ b/includes/User.php @@ -715,7 +715,7 @@ class User { $this->decodeOptions( $s->user_options ); $this->mTouched = wfTimestamp(TS_MW,$s->user_touched); $this->mToken = $s->user_token; - $this->mRegistration = wfTimestamp( TS_MW, $s->user_registration ); + $this->mRegistration = wfTimestampOrNull( TS_MW, $s->user_registration ); $res = $dbr->select( 'user_groups', array( 'ug_group' ), @@ -1534,13 +1534,11 @@ class User { /** * Determine whether the user is a newbie. Newbies are either - * anonymous IPs, or the 1% most recently created accounts. - * Bots and sysops are excluded. + * anonymous IPs, or the most recently created accounts. * @return bool True if it is a newbie. */ function isNewbie() { return !$this->isAllowed( 'autoconfirmed' ); - //return $this->isAnon() || $this->mId > User::getMaxID() * 0.99 && !$this->isAllowed( 'delete' ) && !$this->isBot(); } /**