Remove unused components
authorAlexander Ebert <ebert@woltlab.com>
Mon, 11 Mar 2024 13:02:24 +0000 (14:02 +0100)
committerAlexander Ebert <ebert@woltlab.com>
Mon, 11 Mar 2024 13:02:24 +0000 (14:02 +0100)
wcfsetup/install/files/lib/action/ApiAction.class.php
wcfsetup/install/files/lib/system/endpoint/Parameters.class.php [deleted file]
wcfsetup/install/files/lib/system/endpoint/error/ControllerError.class.php [deleted file]
wcfsetup/install/files/lib/system/endpoint/error/RouteParameterError.class.php [deleted file]
wcfsetup/install/files/lib/system/endpoint/exception/ControllerMalformed.class.php [deleted file]
wcfsetup/install/files/lib/system/endpoint/exception/RouteParameterMismatch.class.php [deleted file]

index 0779b6fc707d9c0360c20e38ee7d629c2e277493..34f3fa02f7781fb13fde091efa84baa5e1522b94 100644 (file)
@@ -13,9 +13,7 @@ use Psr\Http\Server\RequestHandlerInterface;
 use wcf\system\endpoint\event\ControllerCollecting;
 use wcf\system\endpoint\GetRequest;
 use wcf\system\endpoint\IController;
-use wcf\system\endpoint\Parameters;
 use wcf\system\endpoint\PostRequest;
-use wcf\system\endpoint\ApiController;
 use wcf\system\endpoint\RequestType;
 use wcf\system\event\EventHandler;
 use wcf\system\request\RouteHandler;
diff --git a/wcfsetup/install/files/lib/system/endpoint/Parameters.class.php b/wcfsetup/install/files/lib/system/endpoint/Parameters.class.php
deleted file mode 100644 (file)
index 4c508d6..0000000
+++ /dev/null
@@ -1,12 +0,0 @@
-<?php
-
-namespace wcf\system\endpoint;
-
-#[\Attribute(\Attribute::TARGET_PARAMETER)]
-final class Parameters
-{
-    public function __construct(
-        public readonly string $arrayShape = '',
-    ) {
-    }
-}
diff --git a/wcfsetup/install/files/lib/system/endpoint/error/ControllerError.class.php b/wcfsetup/install/files/lib/system/endpoint/error/ControllerError.class.php
deleted file mode 100644 (file)
index 7b2bbc3..0000000
+++ /dev/null
@@ -1,11 +0,0 @@
-<?php
-
-namespace wcf\system\endpoint\error;
-
-enum ControllerError: string
-{
-    case ParameterTypeComplex = 'parameter_type_complex';
-    case ParameterTypeUnknown = 'parameter_type_unknown';
-    case ParameterWithoutType = 'parameter_without_type';
-    case ParameterNotInUri = 'parameter_not_in_uri';
-}
diff --git a/wcfsetup/install/files/lib/system/endpoint/error/RouteParameterError.class.php b/wcfsetup/install/files/lib/system/endpoint/error/RouteParameterError.class.php
deleted file mode 100644 (file)
index eb6c561..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-<?php
-
-namespace wcf\system\endpoint\error;
-
-enum RouteParameterError: string
-{
-    case ExpectedPositiveInteger = 'expected_positive_integer';
-    case ExpectedNonEmptyString = 'expected_non_empty_string';
-}
diff --git a/wcfsetup/install/files/lib/system/endpoint/exception/ControllerMalformed.class.php b/wcfsetup/install/files/lib/system/endpoint/exception/ControllerMalformed.class.php
deleted file mode 100644 (file)
index 7aba9d3..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-<?php
-
-namespace wcf\system\endpoint\exception;
-
-use wcf\system\endpoint\error\ControllerError;
-
-class ControllerMalformed extends \Exception
-{
-    public function __construct(
-        public readonly ControllerError $type,
-        public readonly \ReflectionParameter $parameter,
-    ) {
-
-        parent::__construct(
-            \sprintf(
-                'The parameter "%s" for %s::%s could not be processed.',
-                $parameter->name,
-                $parameter->getDeclaringClass()->name,
-                $parameter->getDeclaringFunction()->name,
-            ),
-        );
-    }
-}
diff --git a/wcfsetup/install/files/lib/system/endpoint/exception/RouteParameterMismatch.class.php b/wcfsetup/install/files/lib/system/endpoint/exception/RouteParameterMismatch.class.php
deleted file mode 100644 (file)
index a513a85..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-<?php
-
-namespace wcf\system\endpoint\exception;
-
-use wcf\system\endpoint\error\RouteParameterError;
-
-final class RouteParameterMismatch extends \Exception
-{
-    public function __construct(
-        public readonly RouteParameterError $type,
-        public readonly string $name,
-    ) {
-        parent::__construct(
-            \sprintf('The parameter "%s" is malformed', $name),
-        );
-    }
-}