mirror of
https://github.com/appwrite/appwrite.git
synced 2026-11-18 20:36:03 +00:00
Fixed worker logger
This commit is contained in:
1 parent
c6c555b763
commit
4d8c2e3cdb
3 files changed
+18
-15
No files matched your search
@@ -3,6 +3,7 @@
|
||||
namespace Appwrite\Resque;
|
||||
|
||||
use Exception;
|
||||
use function var_dump;
|
||||
|
||||
class Worker
|
||||
{
|
||||
@@ -75,8 +76,8 @@ class Worker
|
||||
try {
|
||||
$this->init();
|
||||
} catch(\Throwable $error) {
|
||||
foreach ($this->errorCallbacks as $errorCallback) {
|
||||
$errorCallback($error, "init");
|
||||
foreach (self::$errorCallbacks as $errorCallback) {
|
||||
$errorCallback($error, "init", $this->getName());
|
||||
}
|
||||
|
||||
throw $error;
|
||||
@@ -94,8 +95,8 @@ class Worker
|
||||
try {
|
||||
$this->run();
|
||||
} catch(\Throwable $error) {
|
||||
foreach ($this->errorCallbacks as $errorCallback) {
|
||||
$errorCallback($error, "run");
|
||||
foreach (self::$errorCallbacks as $errorCallback) {
|
||||
$errorCallback($error, "run", $this->getName(), $this->args);
|
||||
}
|
||||
|
||||
throw $error;
|
||||
@@ -113,8 +114,8 @@ class Worker
|
||||
try {
|
||||
$this->shutdown();
|
||||
} catch(\Throwable $error) {
|
||||
foreach ($this->errorCallbacks as $errorCallback) {
|
||||
$errorCallback($error, "shutdown");
|
||||
foreach (self::$errorCallbacks as $errorCallback) {
|
||||
$errorCallback($error, "shutdown", $this->getName());
|
||||
}
|
||||
|
||||
throw $error;
|
||||
|
||||
Reference in new issue
Block a user