mirror of
https://github.com/appwrite/appwrite.git
synced 2026-05-26 13:51:13 +00:00
chore: only sleep if delay is greater than 0 seconds
This prevents the warning: Swoole\Coroutine::sleep(): Timer must be greater than or equal to 0.001
This commit is contained in:
@@ -64,7 +64,9 @@ class ScheduleExecutions extends ScheduleBase
|
||||
$this->updateProjectAccess($schedule['project'], $dbForPlatform);
|
||||
|
||||
\go(function () use ($queueForFunctions, $schedule, $scheduledAt, $delay, $data) {
|
||||
Co::sleep($delay);
|
||||
if ($delay > 0) {
|
||||
Co::sleep($delay);
|
||||
}
|
||||
|
||||
$queueForFunctions->setType('schedule')
|
||||
// Set functionId instead of function as we don't have $dbForProject
|
||||
|
||||
Reference in New Issue
Block a user