From e7f8d8c3b640c7729adec105ed6ce97829539389 Mon Sep 17 00:00:00 2001
From: Philipp Holzer <admin@philipp.info>
Date: Tue, 30 Apr 2019 22:36:28 +0200
Subject: [PATCH] Adding to router

---
 mod/_well_known.php                      | 4 ++--
 src/App/Router.php                       | 2 ++
 src/Module/{Hostxrd.php => HostMeta.php} | 2 +-
 3 files changed, 5 insertions(+), 3 deletions(-)
 rename src/Module/{Hostxrd.php => HostMeta.php} (96%)

diff --git a/mod/_well_known.php b/mod/_well_known.php
index 3dbac799f..3bd86ecc9 100644
--- a/mod/_well_known.php
+++ b/mod/_well_known.php
@@ -3,7 +3,7 @@
 use Friendica\App;
 use Friendica\Core\Config;
 use Friendica\Core\System;
-use Friendica\Module\Hostxrd;
+use Friendica\Module\HostMeta;
 use Friendica\Module\Nodeinfo;
 
 require_once 'mod/xrd.php';
@@ -13,7 +13,7 @@ function _well_known_init(App $a)
 	if ($a->argc > 1) {
 		switch ($a->argv[1]) {
 			case "host-meta":
-				Hostxrd::printHostMeta();
+				HostMeta::printHostMeta();
 				break;
 			case "x-social-relay":
 				wk_social_relay();
diff --git a/src/App/Router.php b/src/App/Router.php
index 039d3e2cf..53fe0689a 100644
--- a/src/App/Router.php
+++ b/src/App/Router.php
@@ -42,6 +42,8 @@ class Router
 	{
 		$this->routeCollector->addRoute(['GET', 'POST'], '/itemsource[/{guid}]', Module\Itemsource::class);
 		$this->routeCollector->addRoute(['GET'],         '/amcd',                Module\AccountManagementControlDocument::class);
+		$this->routeCollector->addRoute(['GET'],         '/host-meta',           Module\HostMeta::class);
+		$this->routeCollector->addRoute(['GET'],         '/hostxrd',             Module\HostMeta::class);
 	}
 
 	public function __construct(RouteCollector $routeCollector = null)
diff --git a/src/Module/Hostxrd.php b/src/Module/HostMeta.php
similarity index 96%
rename from src/Module/Hostxrd.php
rename to src/Module/HostMeta.php
index 4f95ebb45..21953b541 100644
--- a/src/Module/Hostxrd.php
+++ b/src/Module/HostMeta.php
@@ -10,7 +10,7 @@ use Friendica\Util\Crypto;
 /**
  * Prints the host-meta text
  */
-class Hostxrd extends BaseModule
+class HostMeta extends BaseModule
 {
 	public static function rawContent()
 	{