Skip to content

Commit 61afad3

Browse files
authored
Update LaravelHttpClientLoggerServiceProvider.php
Remove the default `null` parameter for the logWith macro as that would cause a failue since the LoggingMiddleware strictly require a logger
1 parent 363110f commit 61afad3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/LaravelHttpClientLoggerServiceProvider.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ public function packageBooted()
5959
}
6060
});
6161

62-
PendingRequest::macro('logWith', function (?HttpLoggerInterface $logger = null): PendingRequest {
62+
PendingRequest::macro('logWith', function (HttpLoggerInterface $logger): PendingRequest {
6363
/** @var \Illuminate\Http\Client\PendingRequest $this */
6464
return $this->withMiddleware((new LoggingMiddleware($logger, new LogAllFilter()))->__invoke());
6565
});

0 commit comments

Comments
 (0)