1
0
Fork 0

Merge pull request #8774 from annando/annando/issue8769

redir - clicking on title of own post leads to access denied error
This commit is contained in:
Hypolite Petovan 2020-06-14 15:03:37 -04:00 committed by GitHub
commit 322ac8945f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -190,6 +190,10 @@ function redir_check_url(string $contact_url, string $url)
}
$url_host = parse_url($url, PHP_URL_HOST);
if (empty($url_host)) {
$url_host = parse_url(DI::baseUrl(), PHP_URL_HOST);
}
$contact_url_host = parse_url($contact_url, PHP_URL_HOST);
if ($url_host == $contact_url_host) {