diff --git a/src/Foundation/Authenticators/BasicAuthenticator.php b/src/Foundation/Authenticators/BasicAuthenticator.php index 28d1ba3f..253d9fe1 100644 --- a/src/Foundation/Authenticators/BasicAuthenticator.php +++ b/src/Foundation/Authenticators/BasicAuthenticator.php @@ -24,8 +24,6 @@ class BasicAuthenticator extends OptionsAuthenticator { public function __construct(string $username, string $password, string $type = 'basic') { - parent::__construct([ - RequestOptions::AUTH => [$username, $password, $type], - ]); + parent::__construct([RequestOptions::AUTH => [$username, $password, $type]]); } } diff --git a/src/Foundation/Authenticators/BearerAuthenticator.php b/src/Foundation/Authenticators/BearerAuthenticator.php index ef111254..f9bb849b 100644 --- a/src/Foundation/Authenticators/BearerAuthenticator.php +++ b/src/Foundation/Authenticators/BearerAuthenticator.php @@ -18,10 +18,6 @@ class BearerAuthenticator extends OptionsAuthenticator { public function __construct(string $token, ?string $bearer = 'Bearer') { - parent::__construct([ - RequestOptions::HEADERS => [ - 'Authorization' => ltrim("$bearer $token"), - ], - ]); + parent::__construct([RequestOptions::HEADERS => ['Authorization' => ltrim("$bearer $token")]]); } } diff --git a/src/Foundation/Authenticators/CertificateAuthenticator.php b/src/Foundation/Authenticators/CertificateAuthenticator.php index a67ecc12..73e22691 100644 --- a/src/Foundation/Authenticators/CertificateAuthenticator.php +++ b/src/Foundation/Authenticators/CertificateAuthenticator.php @@ -18,8 +18,6 @@ class CertificateAuthenticator extends OptionsAuthenticator { public function __construct(string $path, ?string $password = null) { - parent::__construct([ - RequestOptions::CERT => \is_string($password) ? [$path, $password] : $path, - ]); + parent::__construct([RequestOptions::CERT => \is_string($password) ? [$path, $password] : $path]); } } diff --git a/src/Foundation/Concerns/AsBody.php b/src/Foundation/Concerns/AsBody.php index 9bce79dd..b7696d0b 100644 --- a/src/Foundation/Concerns/AsBody.php +++ b/src/Foundation/Concerns/AsBody.php @@ -23,7 +23,7 @@ trait AsBody public function toHttpOptions(): array { return [ - RequestOptions::BODY => Utils::streamFor(http_build_query($this->getOptions())), + RequestOptions::BODY => Utils::streamFor(http_build_query($this->getOptions(), '', '&')), ]; } }