Skip to content

Commit 9500fb9

Browse files
Fix return types
1 parent 50d4f7a commit 9500fb9

File tree

4 files changed

+11
-11
lines changed

4 files changed

+11
-11
lines changed

Transport/AbstractTransport.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ public function __construct(EventDispatcherInterface $dispatcher = null, LoggerI
4141
*
4242
* @return $this
4343
*/
44-
public function setMaxPerSecond(float $rate): self
44+
public function setMaxPerSecond(float $rate): static
4545
{
4646
if (0 >= $rate) {
4747
$rate = 0;

Transport/Smtp/EsmtpTransport.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ public function __construct(string $host = 'localhost', int $port = 0, bool $tls
6666
/**
6767
* @return $this
6868
*/
69-
public function setUsername(string $username): self
69+
public function setUsername(string $username): static
7070
{
7171
$this->username = $username;
7272

@@ -81,7 +81,7 @@ public function getUsername(): string
8181
/**
8282
* @return $this
8383
*/
84-
public function setPassword(string $password): self
84+
public function setPassword(string $password): static
8585
{
8686
$this->password = $password;
8787

Transport/Smtp/SmtpTransport.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ public function getStream(): AbstractStream
6262
*
6363
* @return $this
6464
*/
65-
public function setRestartThreshold(int $threshold, int $sleep = 0): self
65+
public function setRestartThreshold(int $threshold, int $sleep = 0): static
6666
{
6767
$this->restartThreshold = $threshold;
6868
$this->restartThresholdSleep = $sleep;
@@ -104,7 +104,7 @@ public function setPingThreshold(int $seconds): static
104104
*
105105
* @return $this
106106
*/
107-
public function setLocalDomain(string $domain): self
107+
public function setLocalDomain(string $domain): static
108108
{
109109
if ('' !== $domain && '[' !== $domain[0]) {
110110
if (filter_var($domain, \FILTER_VALIDATE_IP, \FILTER_FLAG_IPV4)) {

Transport/Smtp/Stream/SocketStream.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ final class SocketStream extends AbstractStream
3434
/**
3535
* @return $this
3636
*/
37-
public function setTimeout(float $timeout): self
37+
public function setTimeout(float $timeout): static
3838
{
3939
$this->timeout = $timeout;
4040

@@ -51,7 +51,7 @@ public function getTimeout(): float
5151
*
5252
* @return $this
5353
*/
54-
public function setHost(string $host): self
54+
public function setHost(string $host): static
5555
{
5656
$this->host = $host;
5757

@@ -66,7 +66,7 @@ public function getHost(): string
6666
/**
6767
* @return $this
6868
*/
69-
public function setPort(int $port): self
69+
public function setPort(int $port): static
7070
{
7171
$this->port = $port;
7272

@@ -83,7 +83,7 @@ public function getPort(): int
8383
*
8484
* @return $this
8585
*/
86-
public function disableTls(): self
86+
public function disableTls(): static
8787
{
8888
$this->tls = false;
8989

@@ -98,7 +98,7 @@ public function isTLS(): bool
9898
/**
9999
* @return $this
100100
*/
101-
public function setStreamOptions(array $options): self
101+
public function setStreamOptions(array $options): static
102102
{
103103
$this->streamContextOptions = $options;
104104

@@ -117,7 +117,7 @@ public function getStreamOptions(): array
117117
*
118118
* @return $this
119119
*/
120-
public function setSourceIp(string $ip): self
120+
public function setSourceIp(string $ip): static
121121
{
122122
$this->sourceIp = $ip;
123123

0 commit comments

Comments
 (0)