Skip to content
This repository has been archived by the owner on Jul 29, 2021. It is now read-only.

Commit

Permalink
Fix parse_url error with object being returned by url() method.
Browse files Browse the repository at this point in the history
Fixes #6

Thanks to @iboved for suggestion.
  • Loading branch information
bennothommo committed Feb 12, 2021
1 parent 13d19d2 commit 4d0510e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion classes/Normalise.php
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ protected function isExternal(string $url)
protected function getHostname()
{
return $_SERVER['SERVER_NAME']
?? parse_url(url(), PHP_URL_HOST)
?? parse_url(url()->current(), PHP_URL_HOST)
?? null;
}
}

0 comments on commit 4d0510e

Please sign in to comment.