]> git.mxchange.org Git - friendica.git/blobdiff - src/Module/ReallySimpleDiscovery.php
Adhere feedback
[friendica.git] / src / Module / ReallySimpleDiscovery.php
index 50b9660020374f3d7f0b5743ecabd62941d49d65..d76094003feaabb78a60cd36d017782543c7c1c1 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 /**
- * @copyright Copyright (C) 2010-2021, the Friendica project
+ * @copyright Copyright (C) 2010-2023, the Friendica project
  *
  * @license GNU AGPL version 3 or any later version
  *
@@ -22,6 +22,7 @@
 namespace Friendica\Module;
 
 use Friendica\BaseModule;
+use Friendica\Core\System;
 use Friendica\DI;
 use Friendica\Util\XML;
 
@@ -31,12 +32,9 @@ use Friendica\Util\XML;
  */
 class ReallySimpleDiscovery extends BaseModule
 {
-       public static function rawContent()
+       protected function rawContent(array $request = [])
        {
-               header('Content-Type: text/xml');
-
-               $xml = null;
-               echo XML::fromArray([
+               $content = XML::fromArray([
                        'rsd' => [
                                '@attributes' => [
                                        'version' => '1.0',
@@ -68,7 +66,7 @@ class ReallySimpleDiscovery extends BaseModule
                                        ],
                                ],
                        ],
-               ], $xml);
-               exit();
+               ]);
+               System::httpExit($content, Response::TYPE_XML);
        }
 }