Skip to content

Commit

Permalink
Remove unused argument
Browse files Browse the repository at this point in the history
  • Loading branch information
fntneves committed Jun 2, 2019
1 parent 0089aa3 commit e1a9277
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions src/Neves/Events/TransactionalDispatcher.php
Original file line number Diff line number Diff line change
Expand Up @@ -284,17 +284,22 @@ private function matches($pattern, $event) : bool
|| Str::startsWith($event, $pattern);
}

/**
* Setup listeners for transaction events.
*
* @return void
*/
private function setUpListeners() : void
{
$this->dispatcher->listen(TransactionBeginning::class, function ($event) {
$this->dispatcher->listen(TransactionBeginning::class, function () {
$this->onTransactionBegin();
});

$this->dispatcher->listen(TransactionCommitted::class, function ($event) {
$this->dispatcher->listen(TransactionCommitted::class, function () {
$this->onTransactionCommit();
});

$this->dispatcher->listen(TransactionRolledBack::class, function ($event) {
$this->dispatcher->listen(TransactionRolledBack::class, function () {
$this->onTransactionRollback();
});
}
Expand Down

0 comments on commit e1a9277

Please sign in to comment.