Skip to content

Commit

Permalink
Changed order
Browse files Browse the repository at this point in the history
  • Loading branch information
jamielsharief committed Feb 23, 2021
1 parent bd721a6 commit 106ea03
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/Schedule/Event.php
Original file line number Diff line number Diff line change
Expand Up @@ -500,7 +500,7 @@ public function execute(): bool
}

$this->executeCallbacks($this->beforeCallbacks);

$result = false;
switch ($this->type) {
case 'command':
Expand All @@ -513,15 +513,15 @@ public function execute(): bool
$result = $this->dispatchCallable();
break;
}

$this->executeCallbacks($this->afterCallbacks);

if ($result) {
$this->executeCallbacks($this->successCallbacks);
} else {
$this->executeCallbacks($this->errorCallbacks);
}

$this->executeCallbacks($this->afterCallbacks);

return $result;
}

Expand Down

0 comments on commit 106ea03

Please sign in to comment.