X-Git-Url: http://git.cyclocoop.org/?a=blobdiff_plain;f=includes%2FCategory.php;h=6104b8a65aecf90ea4a02362956d775bb2150891;hb=ea0f1b5f004a9dc1cdf5568259c337d45f15ce9b;hp=c22ea64abf8c398a204c1035327e7e0cef3e3cfb;hpb=2c12b1fd2afc14a03c16f05c844320985d911ca0;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/Category.php b/includes/Category.php index c22ea64abf..6104b8a65a 100644 --- a/includes/Category.php +++ b/includes/Category.php @@ -48,7 +48,7 @@ class Category { /** * Set up all member variables using a database query. - * @param integer $mode + * @param int $mode * @throws MWException * @return bool True on success, false on failure. */ @@ -119,9 +119,9 @@ class Category { /** * Factory function. * - * @param array $name A category name (no "Category:" prefix). It need + * @param string $name A category name (no "Category:" prefix). It need * not be normalized, with spaces replaced by underscores. - * @return mixed Category, or false on a totally invalid name + * @return Category|bool Category, or false on a totally invalid name */ public static function newFromName( $name ) { $cat = new self(); @@ -328,7 +328,7 @@ class Category { $dbw = wfGetDB( DB_MASTER ); # Avoid excess contention on the same category (T162121) $name = __METHOD__ . ':' . md5( $this->mName ); - $scopedLock = $dbw->getScopedLockAndFlush( $name, __METHOD__, 1 ); + $scopedLock = $dbw->getScopedLockAndFlush( $name, __METHOD__, 0 ); if ( !$scopedLock ) { return false; }