Merge "(bug 37643) Ensure a session is created when necessary for Captcha"

This commit is contained in:
CSteipp 2012-10-16 23:20:13 +00:00 committed by Gerrit Code Review
commit 6d557c0511

View file

@ -59,6 +59,13 @@ abstract class CaptchaStore {
class CaptchaSessionStore extends CaptchaStore {
protected function __construct() {
// Make sure the session is started
if ( session_id() === '' ) {
wfSetupSession();
}
}
function store( $index, $info ) {
$_SESSION['captcha' . $info['index']] = $info;
}