53 if ( !$this->performer->isAllowed(
'edit' ) ) {
54 $this->result = self::CONSTRAINT_FAILED;
55 return self::CONSTRAINT_FAILED;
58 $this->result = self::CONSTRAINT_PASSED;
59 return self::CONSTRAINT_PASSED;
65 if ( $this->result === self::CONSTRAINT_FAILED ) {
66 if ( !$this->performer->getUser()->isRegistered() ) {
67 $statusValue->
setResult(
false, self::AS_READ_ONLY_PAGE_ANON );
69 $statusValue->fatal(
'readonlytext' );
70 $statusValue->value = self::AS_READ_ONLY_PAGE_LOGGED;
if(ini_get('mbstring.func_overload')) if(!defined('MW_ENTRY_POINT'))
Pre-config setup: Before loading LocalSettings.php.
Verify user permissions: Must have edit rights.
__construct(Authority $performer)
getLegacyStatus()
Get the legacy status for failure (or success)
Generic operation result class Has warning/error list, boolean status and arbitrary value.
setResult( $ok, $value=null)
Change operation result.
Interface for all constraints that can prevent edits.