Skip to content

Commit

Permalink
Merge pull request doctrine#1563 from rawkode/bugfix/incorrect-rollba…
Browse files Browse the repository at this point in the history
…ck-method-name

Fixing method name 'rollBack', which was documented as 'rollback'
  • Loading branch information
deeky666 committed Jan 6, 2016
2 parents 22b9574 + 3c7d92e commit 1697293
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion docs/en/reference/transactions-and-concurrency.rst
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ looks like this:
$em->flush();
$em->getConnection()->commit();
} catch (Exception $e) {
$em->getConnection()->rollback();
$em->getConnection()->rollBack();
throw $e;
}
Expand Down
4 changes: 2 additions & 2 deletions lib/Doctrine/ORM/EntityManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ public function transactional($func)
return $return ?: true;
} catch (Exception $e) {
$this->close();
$this->conn->rollback();
$this->conn->rollBack();

throw $e;
}
Expand All @@ -257,7 +257,7 @@ public function commit()
*/
public function rollback()
{
$this->conn->rollback();
$this->conn->rollBack();
}

/**
Expand Down
2 changes: 1 addition & 1 deletion lib/Doctrine/ORM/UnitOfWork.php
Original file line number Diff line number Diff line change
Expand Up @@ -402,7 +402,7 @@ public function commit($entity = null)
$conn->commit();
} catch (Exception $e) {
$this->em->close();
$conn->rollback();
$conn->rollBack();

$this->afterTransactionRolledBack();

Expand Down

0 comments on commit 1697293

Please sign in to comment.