1
0
Fork 0

Merge pull request #13203 from annando/styled-url

Remove the "www." from the styled URL
This commit is contained in:
Hypolite Petovan 2023-06-06 17:04:06 -04:00 committed by GitHub
commit 50988bf5f1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -570,7 +570,7 @@ class Strings
public static function getStyledURL(string $url): string
{
$parts = parse_url($url);
$scheme = $parts['scheme'] . '://';
$scheme = [$parts['scheme'] . '://www.', $parts['scheme'] . '://'];
$styled_url = str_replace($scheme, '', $url);
if (strlen($styled_url) > 30) {