private function determineMethod(array $server): string
    {
        $mapping = [
            'GET' => self::METHOD_GET,
            'POST' => self::METHOD_POST,
            'PUT' => self::METHOD_PUT,
            'PATCH' => self::METHOD_PATCH,
            'DELETE' => self::METHOD_DELETE,
            'HEAD' => self::METHOD_HEAD,
            'OPTIONS' => self::METHOD_OPTIONS,
            'CONNECT' => self::METHOD_CONNECT,
            'TRACE' => self::METHOD_TRACE
        ];

        $method = $server['REQUEST_METHOD'];

        if (array_key_exists($method, $mapping)) {
            return $mapping[$method];
        }

        return self::METHOD_GET;
    }