diff --git a/composer.lock b/composer.lock index 6c5de17..7577973 100644 --- a/composer.lock +++ b/composer.lock @@ -4,20 +4,20 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "186587c765df966f0c8f7472cb42dd8c", + "content-hash": "8a48f72d362eaf188e2cba67903516a8", "packages": [ { "name": "guzzlehttp/guzzle", - "version": "7.8.0", + "version": "7.8.1", "source": { "type": "git", "url": "https://github.com/guzzle/guzzle.git", - "reference": "1110f66a6530a40fe7aea0378fe608ee2b2248f9" + "reference": "41042bc7ab002487b876a0683fc8dce04ddce104" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/guzzle/zipball/1110f66a6530a40fe7aea0378fe608ee2b2248f9", - "reference": "1110f66a6530a40fe7aea0378fe608ee2b2248f9", + "url": "https://api.github.com/repos/guzzle/guzzle/zipball/41042bc7ab002487b876a0683fc8dce04ddce104", + "reference": "41042bc7ab002487b876a0683fc8dce04ddce104", "shasum": "" }, "require": { @@ -32,11 +32,11 @@ "psr/http-client-implementation": "1.0" }, "require-dev": { - "bamarni/composer-bin-plugin": "^1.8.1", + "bamarni/composer-bin-plugin": "^1.8.2", "ext-curl": "*", "php-http/client-integration-tests": "dev-master#2c025848417c1135031fdf9c728ee53d0a7ceaee as 3.0.999", "php-http/message-factory": "^1.1", - "phpunit/phpunit": "^8.5.29 || ^9.5.23", + "phpunit/phpunit": "^8.5.36 || ^9.6.15", "psr/log": "^1.1 || ^2.0 || ^3.0" }, "suggest": { @@ -114,7 +114,7 @@ ], "support": { "issues": "https://github.com/guzzle/guzzle/issues", - "source": "https://github.com/guzzle/guzzle/tree/7.8.0" + "source": "https://github.com/guzzle/guzzle/tree/7.8.1" }, "funding": [ { @@ -130,7 +130,7 @@ "type": "tidelift" } ], - "time": "2023-08-27T10:20:53+00:00" + "time": "2023-12-03T20:35:24+00:00" }, { "name": "guzzlehttp/promises", diff --git a/src/Mailer.php b/src/Mailer.php index 282b141..b55e404 100644 --- a/src/Mailer.php +++ b/src/Mailer.php @@ -51,7 +51,7 @@ public function __construct( * @param string|null $callback * @param bool $callbackOnSuccess Weather to call you back when the webhook accept this impulse * @param bool $callbackOnFailure Weather to call you back when the webhook reject this impulse or throws error handling it - * @return string + * @return MailerResponse * @throws GuzzleException * @throws RequestFailureException */ @@ -61,7 +61,7 @@ public function send( ?string $callback = null, bool $callbackOnSuccess = false, bool $callbackOnFailure = false, - ): string + ): MailerResponse { $this->withData([ 'mails' => $mails, @@ -70,11 +70,9 @@ public function send( 'callback_on_failure' => $callbackOnFailure, ]); - $response = MailerResponse::new(response: $this->client->post( + return MailerResponse::new(response: $this->client->post( uri: sprintf('applications/%s/mails', $appId), options: $this->getClientOptions(), )); - - return $response->message(); } } \ No newline at end of file