From 3b8b5d226db37582bf76de41ebe0cb52985f3674 Mon Sep 17 00:00:00 2001 From: Wendell Adriel Date: Tue, 14 Oct 2025 15:01:43 +0100 Subject: [PATCH] Add ConnectionException on Http::batch docs --- http-client.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/http-client.md b/http-client.md index 53dc9b0811..9e9eb65328 100644 --- a/http-client.md +++ b/http-client.md @@ -564,6 +564,7 @@ Another way of working with concurrent requests in Laravel is to use the `batch` ```php use Illuminate\Http\Client\Batch; +use Illuminate\Http\Client\ConnectionException; use Illuminate\Http\Client\RequestException; use Illuminate\Http\Client\Response; use Illuminate\Support\Facades\Http; @@ -578,7 +579,7 @@ $responses = Http::batch(fn (Batch $batch) => [ // An individual request has completed successfully... })->then(function (Batch $batch, array $results) { // All requests completed successfully... -})->catch(function (Batch $batch, int|string $key, Response|RequestException $response) { +})->catch(function (Batch $batch, int|string $key, Response|RequestException|ConnectionException $response) { // First batch request failure detected... })->finally(function (Batch $batch, array $results) { // The batch has finished executing...