refactor: Add support for IPv6 addresses in sslip function
This commit is contained in:
parent
306c4dcbc5
commit
9a1c9124ae
1 changed files with 6 additions and 0 deletions
|
|
@ -505,6 +505,12 @@ function sslip(Server $server)
|
||||||
|
|
||||||
return "http://$baseIp.sslip.io";
|
return "http://$baseIp.sslip.io";
|
||||||
}
|
}
|
||||||
|
// ipv6
|
||||||
|
if (str($server->ip)->contains(':')) {
|
||||||
|
$ipv6 = str($server->ip)->replace(':', '-');
|
||||||
|
|
||||||
|
return "http://{$ipv6}.sslip.io";
|
||||||
|
}
|
||||||
|
|
||||||
return "http://{$server->ip}.sslip.io";
|
return "http://{$server->ip}.sslip.io";
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue