Force redirect to core's login/index page
authorAlexander Ebert <ebert@woltlab.com>
Sun, 23 Apr 2017 14:06:57 +0000 (16:06 +0200)
committerAlexander Ebert <ebert@woltlab.com>
Sun, 23 Apr 2017 14:06:57 +0000 (16:06 +0200)
wcfsetup/install/files/lib/system/request/RequestHandler.class.php

index 0bad23ca7f73ff0848645c8d179d0f7d150ddec3..db7514d7008b76cf8b0c35f6c6cbc275b26e9335 100644 (file)
@@ -148,6 +148,15 @@ class RequestHandler extends SingletonFactory {
                                unset($routeData['pageType']);
                        }
                        else {
+                               if ($this->isACPRequest() && ($controller === 'login' || $controller === 'index') && $application !== 'wcf') {
+                                       HeaderUtil::redirect(
+                                               LinkHandler::getInstance()->getLink(ucfirst($controller)),
+                                               true,
+                                               false
+                                       );
+                                       exit;
+                               }
+                               
                                $classData = ControllerMap::getInstance()->resolve($application, $controller, $this->isACPRequest());
                                if (is_string($classData)) {
                                        $this->redirect($routeData, $application, $classData);