Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/Instrumentation/Guzzle/src/GuzzleInstrumentation.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
namespace OpenTelemetry\Contrib\Instrumentation\Guzzle;

use function get_cfg_var;
use GuzzleHttp\ClientInterface;
use GuzzleHttp\Client;
use GuzzleHttp\Promise\PromiseInterface;
use OpenTelemetry\API\Globals;
use OpenTelemetry\API\Instrumentation\CachedInstrumentation;
Expand Down Expand Up @@ -35,9 +35,9 @@ public static function register(): void
);

hook(
ClientInterface::class,
Client::class,
'transfer',
pre: static function (ClientInterface $client, array $params, string $class, string $function, ?string $filename, ?int $lineno) use ($instrumentation): array {
pre: static function (Client $client, array $params, string $class, string $function, ?string $filename, ?int $lineno) use ($instrumentation): array {
$request = $params[0];
assert($request instanceof RequestInterface);

Expand Down Expand Up @@ -84,7 +84,7 @@ public static function register(): void

return [$request];
},
post: static function (ClientInterface $client, array $params, PromiseInterface $promise, ?Throwable $exception): void {
post: static function (Client $client, array $params, PromiseInterface $promise, ?Throwable $exception): void {
$scope = Context::storage()->scope();
$scope?->detach();

Expand Down
Loading