mirror of
https://github.com/appwrite/appwrite.git
synced 2026-05-26 13:51:13 +00:00
fix pool is empty webhook worker
This commit is contained in:
+4
-1
@@ -240,7 +240,10 @@ $worker
|
||||
->inject('error')
|
||||
->inject('logger')
|
||||
->inject('log')
|
||||
->action(function (Throwable $error, ?Logger $logger, Log $log) use ($queueName) {
|
||||
->inject('pools')
|
||||
->action(function (Throwable $error, ?Logger $logger, Log $log, Group $pools) use ($queueName) {
|
||||
$pools->reclaim();
|
||||
|
||||
$version = App::getEnv('_APP_VERSION', 'UNKNOWN');
|
||||
|
||||
if ($error instanceof PDOException) {
|
||||
|
||||
@@ -49,6 +49,7 @@ class Webhooks extends Action
|
||||
*/
|
||||
public function action(Message $message, Database $dbForConsole, Mail $queueForMails, Log $log): void
|
||||
{
|
||||
$this->errors = [];
|
||||
$payload = $message->getPayload() ?? [];
|
||||
|
||||
if (empty($payload)) {
|
||||
|
||||
Reference in New Issue
Block a user