isInternalURL() treats everything as internal that resides on the same subdomain
authorMarcel Werk <burntime@woltlab.com>
Thu, 6 Aug 2020 20:45:09 +0000 (22:45 +0200)
committerMarcel Werk <burntime@woltlab.com>
Thu, 6 Aug 2020 20:45:09 +0000 (22:45 +0200)
wcfsetup/install/files/lib/system/application/ApplicationHandler.class.php

index 675a807fd248dcf3d0f115db2b013c569b33f190..b3a95ffcb055ed6f3b79e6f502cff522baf4ced1 100644 (file)
@@ -200,8 +200,9 @@ class ApplicationHandler extends SingletonFactory {
                $protocolRegex = new Regex('^https(?=://)');
                if (empty($this->pageURLs)) {
                        foreach ($this->getApplications() as $application) {
-                               $this->pageURLs[] = preg_replace('~/$~', '', $protocolRegex->replace($application->getPageURL(), 'http'));
+                               $this->pageURLs[] = preg_replace('~/$~', '', $protocolRegex->replace(RouteHandler::getProtocol() . $application->domainName, 'http'));
                        }
+                       $this->pageURLs = array_unique($this->pageURLs);
                }
                
                foreach ($this->pageURLs as $pageURL) {