Avoid unstubbing $wgUser before the end of Setup.php in User::getBlockedStatus()
authorBrad Jorsch <bjorsch@wikimedia.org>
Wed, 3 Feb 2016 17:33:25 +0000 (12:33 -0500)
committerAnomie <bjorsch@wikimedia.org>
Wed, 3 Feb 2016 21:46:12 +0000 (21:46 +0000)
commit6eec9fb3553d759190f010b38db39d01645922bb
treed64b29d8e503518030dde9bff17f27479f025269
parent35c38ce319563889ccd61f998223e61316a35f6a
Avoid unstubbing $wgUser before the end of Setup.php in User::getBlockedStatus()

Autocreation needs to check if the current IP is blocked from account
creation.

There are two ways we could go here: treat $wgUser as logged-out, or
assume it will eventually be the user name specified by the session.
This patch chooses the former, by the logic that at this early point in
the setup process we don't have a logged-in user determined yet so no
username can really be considered to match the logged-in user.

Bug: T124367
Change-Id: I631bec85291b57f07c378cf6554a8f06cf3fb00c
includes/user/User.php