From 241fdf94f07c318983a991d69bf17848a386d513 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jaime=20Pe=CC=81rez=20Crespo?= <jaime.perez@uninett.no>
Date: Wed, 17 Oct 2018 16:30:47 +0200
Subject: [PATCH] Refactor SimpleSAML\Router to SimpleSAML\HTTP\Router.

---
 lib/SimpleSAML/{ => HTTP}/Router.php | 9 ++++++---
 lib/SimpleSAML/Module.php            | 2 +-
 2 files changed, 7 insertions(+), 4 deletions(-)
 rename lib/SimpleSAML/{ => HTTP}/Router.php (93%)

diff --git a/lib/SimpleSAML/Router.php b/lib/SimpleSAML/HTTP/Router.php
similarity index 93%
rename from lib/SimpleSAML/Router.php
rename to lib/SimpleSAML/HTTP/Router.php
index fe6e56883..e537092a9 100644
--- a/lib/SimpleSAML/Router.php
+++ b/lib/SimpleSAML/HTTP/Router.php
@@ -1,6 +1,9 @@
 <?php
 
-namespace SimpleSAML;
+namespace SimpleSAML\HTTP;
+
+use SimpleSAML\Configuration;
+use SimpleSAML\Session;
 
 use Symfony\Component\EventDispatcher\EventDispatcher;
 use Symfony\Component\HttpFoundation\Request;
@@ -32,7 +35,7 @@ class Router
     /** @var Request */
     protected $request;
 
-    /** @var \SimpleSAML\ModuleControllerResolver */
+    /** @var \SimpleSAML\Module\ControllerResolver */
     protected $resolver;
 
     /** @var \SimpleSAML\Session */
@@ -51,7 +54,7 @@ class Router
     {
         $this->arguments = new ArgumentResolver();
         $this->context = new RequestContext();
-        $this->resolver = new ModuleControllerResolver($module);
+        $this->resolver = new \SimpleSAML\Module\ControllerResolver($module);
         $this->dispatcher = new EventDispatcher();
     }
 
diff --git a/lib/SimpleSAML/Module.php b/lib/SimpleSAML/Module.php
index 744dea83f..775a585cf 100644
--- a/lib/SimpleSAML/Module.php
+++ b/lib/SimpleSAML/Module.php
@@ -166,7 +166,7 @@ class Module
 
         $config = Configuration::getInstance();
         if ($config->getBoolean('usenewui', false) === true) {
-            $router = new Router($module);
+            $router = new HTTP\Router($module);
             try {
                 return $router->process();
             } catch (\Symfony\Component\Config\Exception\FileLocatorFileNotFoundException $e) {
-- 
GitLab