Add wpSkipCookieCheck to allow bots to skip the cookie check

This commit is contained in:
Bryan Tong Minh 2008-05-31 08:54:45 +00:00
parent 8bf723950d
commit 29c73e8265

View file

@ -36,7 +36,7 @@ class LoginForm {
var $mName, $mPassword, $mRetype, $mReturnTo, $mCookieCheck, $mPosted;
var $mAction, $mCreateaccount, $mCreateaccountMail, $mMailmypassword;
var $mLoginattempt, $mRemember, $mEmail, $mDomain, $mLanguage;
var $mLoginattempt, $mRemember, $mEmail, $mDomain, $mLanguage, $mSkipCookieCheck;
/**
* Constructor
@ -63,6 +63,7 @@ class LoginForm {
$this->mAction = $request->getVal( 'action' );
$this->mRemember = $request->getCheck( 'wpRemember' );
$this->mLanguage = $request->getText( 'uselang' );
$this->mSkipCookieCheck = $request->getCheck( 'wpSkipCookieCheck' );
if( $wgEnableEmail ) {
$this->mEmail = $request->getText( 'wpEmail' );
@ -501,7 +502,7 @@ class LoginForm {
}
$wgUser->setCookies();
if( $this->hasSessionCookie() ) {
if( $this->hasSessionCookie() || $this->mSkipCookieCheck ) {
/* Replace the language object to provide user interface in correct
* language immediately on this first page load.
*/