Skip to content

Commit

Permalink
Update EventLoop.php
Browse files Browse the repository at this point in the history
  • Loading branch information
VennDev authored Aug 3, 2024
1 parent aecf49e commit 8a64ebe
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/vennv/vapm/EventLoop.php
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,11 @@ protected static function run(): void
}

if ($fiber->isTerminated() && ($promise->getStatus() !== StatusPromise::PENDING || $promise->isJustGetResult())) {
if ($promise->isJustGetResult()) $promise->setResult($fiber->getReturn());
try {
if ($promise->isJustGetResult()) $promise->setResult($fiber->getReturn());
} catch (Throwable $e) {
GlobalLogger::get()->warning($e->getMessage());

Check failure on line 203 in src/vennv/vapm/EventLoop.php

View workflow job for this annotation

GitHub Actions / Jobs (8.2)

Call to static method get() on an unknown class vennv\vapm\GlobalLogger.
}
MicroTask::addTask($id, $promise);
self::removeQueue($id);
}
Expand Down

0 comments on commit 8a64ebe

Please sign in to comment.