diff options
Diffstat (limited to 'includes/libs/lockmanager/QuorumLockManager.php')
-rw-r--r-- | includes/libs/lockmanager/QuorumLockManager.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/includes/libs/lockmanager/QuorumLockManager.php b/includes/libs/lockmanager/QuorumLockManager.php index 1d2e21aa0d70..1ef4642a84a6 100644 --- a/includes/libs/lockmanager/QuorumLockManager.php +++ b/includes/libs/lockmanager/QuorumLockManager.php @@ -98,7 +98,7 @@ abstract class QuorumLockManager extends LockManager { $bucket = $this->getBucketFromPath( $path ); $pathsToUnlock[$bucket][$type][] = $path; } - if ( !count( $this->locksHeld[$path] ) ) { + if ( $this->locksHeld[$path] === [] ) { unset( $this->locksHeld[$path] ); // no SH or EX locks left for key } } @@ -110,7 +110,7 @@ abstract class QuorumLockManager extends LockManager { foreach ( $pathsToUnlock as $bucket => $pathsToUnlockByType ) { $status->merge( $this->doUnlockingRequestBucket( $bucket, $pathsToUnlockByType ) ); } - if ( !count( $this->locksHeld ) ) { + if ( $this->locksHeld === [] ) { $status->merge( $this->releaseAllLocks() ); $this->degradedBuckets = []; // safe to retry the normal quorum } |