|
@@ 1004-1011 (lines=8) @@
|
| 1001 |
|
|
| 1002 |
|
// Permissions check |
| 1003 |
|
$status = $this->checkAccountCreatePermissions( $creator ); |
| 1004 |
|
if ( !$status->isGood() ) { |
| 1005 |
|
$this->logger->debug( __METHOD__ . ': {creator} cannot create users: {reason}', [ |
| 1006 |
|
'user' => $username, |
| 1007 |
|
'creator' => $creator->getName(), |
| 1008 |
|
'reason' => $status->getWikiText( null, null, 'en' ) |
| 1009 |
|
] ); |
| 1010 |
|
return AuthenticationResponse::newFail( $status->getMessage() ); |
| 1011 |
|
} |
| 1012 |
|
|
| 1013 |
|
$status = $this->canCreateAccount( $username, User::READ_LOCKING ); |
| 1014 |
|
if ( !$status->isGood() ) { |
|
@@ 1014-1021 (lines=8) @@
|
| 1011 |
|
} |
| 1012 |
|
|
| 1013 |
|
$status = $this->canCreateAccount( $username, User::READ_LOCKING ); |
| 1014 |
|
if ( !$status->isGood() ) { |
| 1015 |
|
$this->logger->debug( __METHOD__ . ': {user} cannot be created: {reason}', [ |
| 1016 |
|
'user' => $username, |
| 1017 |
|
'creator' => $creator->getName(), |
| 1018 |
|
'reason' => $status->getWikiText( null, null, 'en' ) |
| 1019 |
|
] ); |
| 1020 |
|
return AuthenticationResponse::newFail( $status->getMessage() ); |
| 1021 |
|
} |
| 1022 |
|
|
| 1023 |
|
$user = User::newFromName( $username, 'creatable' ); |
| 1024 |
|
foreach ( $reqs as $req ) { |