diff --git a/src/Endpoints/Delegates/HandlesTasks.php b/src/Endpoints/Delegates/HandlesTasks.php index 58c0080f2..44fbb77b3 100644 --- a/src/Endpoints/Delegates/HandlesTasks.php +++ b/src/Endpoints/Delegates/HandlesTasks.php @@ -9,6 +9,7 @@ use Meilisearch\Contracts\TasksQuery; use Meilisearch\Contracts\TasksResults; use Meilisearch\Endpoints\Tasks; +use Meilisearch\Exceptions\TimeOutException; trait HandlesTasks { @@ -38,11 +39,17 @@ public function cancelTasks(CancelTasksQuery $options = null): array return $this->tasks->cancelTasks($options); } + /** + * @throws TimeOutException + */ public function waitForTask($uid, int $timeoutInMs = 5000, int $intervalInMs = 50): array { return $this->tasks->waitTask($uid, $timeoutInMs, $intervalInMs); } + /** + * @throws TimeOutException + */ public function waitForTasks($uids, int $timeoutInMs = 5000, int $intervalInMs = 50): array { return $this->tasks->waitTasks($uids, $timeoutInMs, $intervalInMs);