Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit d282198

Browse filesBrowse files
committed
Fix compatibility with async-core 0.5
1 parent 5b27533 commit d282198
Copy full SHA for d282198

File tree

2 files changed

+6
-4
lines changed
Filter options

2 files changed

+6
-4
lines changed

‎src/Symfony/Component/Mailer/Bridge/Amazon/Transport/SesApiAsyncAwsTransport.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Mailer/Bridge/Amazon/Transport/SesApiAsyncAwsTransport.php
+3-2Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111

1212
namespace Symfony\Component\Mailer\Bridge\Amazon\Transport;
1313

14+
use AsyncAws\Core\Configuration;
1415
use AsyncAws\Ses\Input\SendEmailRequest;
1516
use AsyncAws\Ses\ValueObject\Content;
1617
use Symfony\Component\Mailer\Envelope;
@@ -28,8 +29,8 @@ class SesApiAsyncAwsTransport extends SesHttpAsyncAwsTransport
2829
public function __toString(): string
2930
{
3031
$configuration = $this->sesClient->getConfiguration();
31-
if (!$configuration->isDefault('endpoint')) {
32-
$endpoint = parse_url($configuration->get('endpoint'));
32+
if (($endpoint = $configuration->get('endpoint')) === (new Configuration())->get('endpoint')) {
33+
$endpoint = parse_url($endpoint);
3334
$host = $endpoint['host'].($endpoint['port'] ?? null ? ':'.$endpoint['port'] : '');
3435
} else {
3536
$host = $configuration->get('region');

‎src/Symfony/Component/Mailer/Bridge/Amazon/Transport/SesHttpAsyncAwsTransport.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Mailer/Bridge/Amazon/Transport/SesHttpAsyncAwsTransport.php
+3-2Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111

1212
namespace Symfony\Component\Mailer\Bridge\Amazon\Transport;
1313

14+
use AsyncAws\Core\Configuration;
1415
use AsyncAws\Core\Exception\Http\HttpException;
1516
use AsyncAws\Ses\Input\SendEmailRequest;
1617
use AsyncAws\Ses\SesClient;
@@ -39,8 +40,8 @@ public function __construct(SesClient $sesClient, EventDispatcherInterface $disp
3940
public function __toString(): string
4041
{
4142
$configuration = $this->sesClient->getConfiguration();
42-
if (!$configuration->isDefault('endpoint')) {
43-
$endpoint = parse_url($configuration->get('endpoint'));
43+
if (($endpoint = $configuration->get('endpoint')) === (new Configuration())->get('endpoint')) {
44+
$endpoint = parse_url($endpoint);
4445
$host = $endpoint['host'].($endpoint['port'] ?? null ? ':'.$endpoint['port'] : '');
4546
} else {
4647
$host = $configuration->get('region');

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.