mirror of
https://github.com/appwrite/appwrite.git
synced 2026-05-26 13:51:13 +00:00
reset worker
This commit is contained in:
+2
-8
@@ -62,13 +62,7 @@ Server::setResource('project', function (Message $message, Database $dbForPlatfo
|
||||
return $project;
|
||||
}
|
||||
|
||||
// NOT all workers need valid DB config so we return empty if this fails
|
||||
try {
|
||||
return $dbForPlatform->getDocument('projects', $project->getId());
|
||||
} catch (\Throwable $e) {
|
||||
return new Document([]);
|
||||
}
|
||||
|
||||
return $dbForPlatform->getDocument('projects', $project->getId());
|
||||
}, ['message', 'dbForPlatform']);
|
||||
|
||||
Server::setResource('dbForProject', function (Cache $cache, Registry $register, Message $message, Document $project, Database $dbForPlatform) {
|
||||
@@ -435,4 +429,4 @@ $worker->workerStart()
|
||||
Console::info("Worker $workerName started");
|
||||
});
|
||||
|
||||
$worker->start();
|
||||
$worker->start();
|
||||
Reference in New Issue
Block a user