Bugfix: Changed "if( ! $prev[$pointer])" to "if( ! isset($prev[$pointer]) )" in
Query.php line 538. Change: Changed return value of pessimistic locking releasedAgedLocks to return the number of released locks.
This commit is contained in:
parent
1fd421d09e
commit
7b19bef12b
@ -210,7 +210,7 @@ class Doctrine_Locking_Manager_Pessimistic
|
||||
* When called without parameters all locks older than 15 minutes are released.
|
||||
*
|
||||
* @param integer $age The maximum valid age of locks in seconds
|
||||
* @return boolean TRUE if locks have been released, FALSE if no locks were released
|
||||
* @return integer The number of locks that have been released
|
||||
* @throws Doctrine_Locking_Exception If the release process failed due to database errors
|
||||
*/
|
||||
public function releaseAgedLocks($age = 900)
|
||||
@ -226,7 +226,7 @@ class Doctrine_Locking_Manager_Pessimistic
|
||||
|
||||
$count = $stmt->rowCount();
|
||||
|
||||
return ($count > 0);
|
||||
return $count;
|
||||
}
|
||||
catch(PDOException $pdoe)
|
||||
{
|
||||
|
@ -535,7 +535,7 @@ class Doctrine_Query extends Doctrine_Access {
|
||||
$pointer = $this->joins[$name];
|
||||
$alias = $this->tables[$pointer]->getAlias($name);
|
||||
$fk = $this->tables[$pointer]->getForeignKey($alias);
|
||||
if( ! $prev[$pointer])
|
||||
if( ! isset($prev[$pointer]) )
|
||||
continue;
|
||||
|
||||
$last = $prev[$pointer]->getLast();
|
||||
|
Loading…
x
Reference in New Issue
Block a user