User: Remove useless check from deprecated isBlocked method
Remove call to AbstractBlock::appliesToRight, because it always returns true for 'edit', so checking it is equivalent to adding && true. Although this method is deprecated, this is worth tidying this up since it is confusing and gets us one step closer to removing the 'edit' case altogether. Change-Id: I479d6c866ec13a791873042e623fa841dd5bebf2
This commit is contained in:
parent
075807151a
commit
9132b2e372
1 changed files with 1 additions and 2 deletions
|
|
@ -1899,8 +1899,7 @@ class User implements IDBAccessObject, UserIdentity {
|
|||
* @return bool True if blocked, false otherwise
|
||||
*/
|
||||
public function isBlocked( $fromReplica = true ) {
|
||||
return $this->getBlock( $fromReplica ) instanceof AbstractBlock &&
|
||||
$this->getBlock()->appliesToRight( 'edit' );
|
||||
return $this->getBlock( $fromReplica ) instanceof AbstractBlock;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in a new issue