Skip to content

Commit 374eaa0

Browse files
Make domain required in currentTunnelUrl
These methods are never passed null anyway. Co-Authored-By: Mateus Junges <[email protected]>
1 parent 628997d commit 374eaa0

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

cli/Valet/Cloudflared.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ public function __construct(public CommandLine $cli, public Brew $brew)
1010
{
1111
}
1212

13-
public function currentTunnelUrl(?string $domain = null)
13+
public function currentTunnelUrl(string $domain): ?string
1414
{
1515
return $this->currentCloudflaredTunnels()[$domain] ?? false;
1616
}

cli/Valet/Expose.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ class Expose
99
{
1010
public function __construct(public Composer $composer, public CommandLine $cli) {}
1111

12-
public function currentTunnelUrl(?string $domain = null): ?string
12+
public function currentTunnelUrl(string $domain): ?string
1313
{
1414
$endpoint = 'http://127.0.0.1:4040/api/tunnels';
1515

cli/Valet/Ngrok.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ public function __construct(public CommandLine $cli, public Brew $brew) {}
1818
/**
1919
* Get the current tunnel URL from the Ngrok API.
2020
*/
21-
public function currentTunnelUrl(?string $domain = null): string
21+
public function currentTunnelUrl(string $domain): string
2222
{
2323
// wait a second for ngrok to start before attempting to find available tunnels
2424
sleep(1);

0 commit comments

Comments
 (0)