Negotiation \ Exception \ InvalidArgument
The header string should not be empty. Negotiation\Exception\InvalidArgument thrown with message "The header string should not be empty." Stacktrace: #26 Negotiation\Exception\InvalidArgument in /home/rdc/rdc.refugee/production/vendor/willdurand/negotiation/src/Negotiation/AbstractNegotiator.php:23 #25 Negotiation\AbstractNegotiator:getBest in /home/rdc/rdc.refugee/production/src/Http/Home/Responder.php:21 #24 App\Http\Home\Responder:found in /home/rdc/rdc.refugee/production/vendor/jnjxp/adr/src/Respond/AbstractResponder.php:41 #23 Jnjxp\Adr\Respond\AbstractResponder:__invoke in /home/rdc/rdc.refugee/production/vendor/jnjxp/adr/src/Process/AbstractActionHandler.php:56 #22 Jnjxp\Adr\Process\AbstractActionHandler:act in /home/rdc/rdc.refugee/production/vendor/jnjxp/adr/src/Process/AbstractActionHandler.php:24 #21 Jnjxp\Adr\Process\AbstractActionHandler:handle in /home/rdc/rdc.refugee/production/vendor/jnjxp/adr/src/Process/AbstractActionHandler.php:18 #20 Jnjxp\Adr\Process\AbstractActionHandler:process in /home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Next.php:49 #19 Laminas\Stratigility\Next:handle in /home/rdc/rdc.refugee/production/vendor/jnjxp/aura-adr/src/AuraRouteAction.php:34 #18 Jnjxp\AuraAdr\AuraRouteAction:process in /home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Next.php:49 #17 Laminas\Stratigility\Next:handle in /home/rdc/rdc.refugee/production/vendor/jnjxp/router/src/Process/AbstractRouteRequest.php:20 #16 Jnjxp\Router\Process\AbstractRouteRequest:process in /home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Next.php:49 #15 Laminas\Stratigility\Next:handle in /home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Middleware/PathMiddlewareDecorator.php:37 #14 Laminas\Stratigility\Middleware\PathMiddlewareDecorator:process in /home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Next.php:49 #13 Laminas\Stratigility\Next:handle in /home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Middleware/PathMiddlewareDecorator.php:37 #12 Laminas\Stratigility\Middleware\PathMiddlewareDecorator:process in /home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Next.php:49 #11 Laminas\Stratigility\Next:handle in /home/rdc/rdc.refugee/production/vendor/jnjxp/auth/src/Middleware/ResumeAuthentication.php:28 #10 Jnjxp\Auth\Middleware\ResumeAuthentication:process in /home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Next.php:49 #9 Laminas\Stratigility\Next:handle in /home/rdc/rdc.refugee/production/vendor/middlewares/aura-session/src/AuraSession.php:74 #8 Middlewares\AuraSession:process in /home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Next.php:49 #7 Laminas\Stratigility\Next:handle in /home/rdc/rdc.refugee/production/vendor/jnjxp/production-host/src/ProductionHost.php:33 #6 Jnjxp\ProductionHost\ProductionHost:process in /home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Next.php:49 #5 Laminas\Stratigility\Next:handle in /home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php:75 #4 Laminas\Stratigility\MiddlewarePipe:process in /home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php:64 #3 Laminas\Stratigility\MiddlewarePipe:handle in /home/rdc/rdc.refugee/production/vendor/laminas/laminas-httphandlerrunner/src/RequestHandlerRunner.php:96 #2 Laminas\HttpHandlerRunner\RequestHandlerRunner:run in /home/rdc/rdc.refugee/production/vendor/jnjxp/app/src/App.php:33 #1 Jnjxp\App\App:run in /home/rdc/rdc.refugee/production/public/index.php:26 #0 {closure} in /home/rdc/rdc.refugee/production/public/index.php:27
Stack frames (27)
26
Negotiation\Exception\InvalidArgument
/vendor/willdurand/negotiation/src/Negotiation/AbstractNegotiator.php23
25
Negotiation\AbstractNegotiator getBest
/src/Http/Home/Responder.php21
24
App\Http\Home\Responder found
/vendor/jnjxp/adr/src/Respond/AbstractResponder.php41
23
Jnjxp\Adr\Respond\AbstractResponder __invoke
/vendor/jnjxp/adr/src/Process/AbstractActionHandler.php56
22
Jnjxp\Adr\Process\AbstractActionHandler act
/vendor/jnjxp/adr/src/Process/AbstractActionHandler.php24
21
Jnjxp\Adr\Process\AbstractActionHandler handle
/vendor/jnjxp/adr/src/Process/AbstractActionHandler.php18
20
Jnjxp\Adr\Process\AbstractActionHandler process
/vendor/laminas/laminas-stratigility/src/Next.php49
19
Laminas\Stratigility\Next handle
/vendor/jnjxp/aura-adr/src/AuraRouteAction.php34
18
Jnjxp\AuraAdr\AuraRouteAction process
/vendor/laminas/laminas-stratigility/src/Next.php49
17
Laminas\Stratigility\Next handle
/vendor/jnjxp/router/src/Process/AbstractRouteRequest.php20
16
Jnjxp\Router\Process\AbstractRouteRequest process
/vendor/laminas/laminas-stratigility/src/Next.php49
15
Laminas\Stratigility\Next handle
/vendor/laminas/laminas-stratigility/src/Middleware/PathMiddlewareDecorator.php37
14
Laminas\Stratigility\Middleware\PathMiddlewareDecorator process
/vendor/laminas/laminas-stratigility/src/Next.php49
13
Laminas\Stratigility\Next handle
/vendor/laminas/laminas-stratigility/src/Middleware/PathMiddlewareDecorator.php37
12
Laminas\Stratigility\Middleware\PathMiddlewareDecorator process
/vendor/laminas/laminas-stratigility/src/Next.php49
11
Laminas\Stratigility\Next handle
/vendor/jnjxp/auth/src/Middleware/ResumeAuthentication.php28
10
Jnjxp\Auth\Middleware\ResumeAuthentication process
/vendor/laminas/laminas-stratigility/src/Next.php49
9
Laminas\Stratigility\Next handle
/vendor/middlewares/aura-session/src/AuraSession.php74
8
Middlewares\AuraSession process
/vendor/laminas/laminas-stratigility/src/Next.php49
7
Laminas\Stratigility\Next handle
/vendor/jnjxp/production-host/src/ProductionHost.php33
6
Jnjxp\ProductionHost\ProductionHost process
/vendor/laminas/laminas-stratigility/src/Next.php49
5
Laminas\Stratigility\Next handle
/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php75
4
Laminas\Stratigility\MiddlewarePipe process
/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php64
3
Laminas\Stratigility\MiddlewarePipe handle
/vendor/laminas/laminas-httphandlerrunner/src/RequestHandlerRunner.php96
2
Laminas\HttpHandlerRunner\RequestHandlerRunner run
/vendor/jnjxp/app/src/App.php33
1
Jnjxp\App\App run
/public/index.php26
0
{closure}
/public/index.php27
/home/rdc/rdc.refugee/production/vendor/willdurand/negotiation/src/Negotiation/AbstractNegotiator.php
 
use Negotiation\Exception\InvalidArgument;
use Negotiation\Exception\InvalidHeader;
 
abstract class AbstractNegotiator
{
    /**
     * @param string $header     A string containing an `Accept|Accept-*` header.
     * @param array  $priorities A set of server priorities.
     *
     * @return AcceptHeader|null best matching type
     */
    public function getBest($header, array $priorities, $strict = false)
    {
        if (empty($priorities)) {
            throw new InvalidArgument('A set of server priorities should be given.');
        }
 
        if (!$header) {
            throw new InvalidArgument('The header string should not be empty.');
        }
 
        // Once upon a time, two `array_map` calls were sitting there, but for
        // some reasons, they triggered `E_WARNING` time to time (because of
        // PHP bug [55416](https://bugs.php.net/bug.php?id=55416). Now, they
        // are gone.
        // See: https://github.com/willdurand/Negotiation/issues/81
        $acceptedHeaders = array();
        foreach ($this->parseHeader($header) as $h) {
            try {
                $acceptedHeaders[] = $this->acceptFactory($h);
            } catch (Exception\Exception $e) {
                if ($strict) {
                    throw $e;
                }
            }
        }
        $acceptedPriorities = array();
        foreach ($priorities as $p) {
            $acceptedPriorities[] = $this->acceptFactory($p);
/home/rdc/rdc.refugee/production/src/Http/Home/Responder.php
 
declare(strict_types=1);
 
namespace App\Http\Home;
 
use App\Http\Responder as BaseResponder;
use Psr\Http\Message\ResponseFactoryInterface;
use Psr\Http\Message\ServerRequestInterface;
use Psr\Http\Message\ResponseInterface;
use Slim\Views\PhpRenderer;
use Aura\Auth\Auth;
 
class Responder extends BaseResponder
{
    protected function found() : void
    {
        $negotiator = new \Negotiation\LanguageNegotiator();
        $header = $this->request->getHeaderLine('Accept-Language');
        $langs = $this->payload->getResult()['langs'];
        $bestLanguage = $negotiator->getBest($header, $langs);
 
        $code = $bestLanguage ? $bestLanguage->getType() : 'en';
        $this->redirect("/$code");
    }
}
 
/home/rdc/rdc.refugee/production/vendor/jnjxp/adr/src/Respond/AbstractResponder.php
    public static function accepts() : array
    {
        return ['application/json'];
    }
 
    public function __construct(ResponseFactoryInterface $responseFactory)
    {
        $this->responseFactory = $responseFactory;
    }
 
    public function __invoke(
        ServerRequestInterface $request,
        DomainPayload $payload = null
    ) : ResponseInterface {
        $this->request  = $request;
        $this->payload  = $payload;
        $this->response = $this->responseFactory->createResponse();
        $this->init();
        $method = $this->getMethod();
        $this->$method();
        return $this->response;
    }
 
    protected function init() : void
    {
    }
 
    protected function getMethod() : string
    {
        if (! $this->payload) {
            return 'noContent';
        }
 
        $method = str_replace('_', '', strtolower($this->payload->getStatus()));
        return method_exists($this, $method) ? $method : 'unknown';
    }
 
    protected function noContent() : void
    {
        $this->response = $this->response->withStatus(self::STATUS_NO_CONTENT);
/home/rdc/rdc.refugee/production/vendor/jnjxp/adr/src/Process/AbstractActionHandler.php
 
    protected function act(ServerRequestInterface $request, ActionInterface $action) : ResponseInterface
    {
        $responder = $this->getResponder($action);
 
        if (! $responder) {
            throw new \Exception('No Responder!');
        }
 
        $domain = $this->getDomain($action);
 
        if (! $domain) {
            return $responder($request);
        }
 
        $input  = $this->getInput($action);
        $params = $input ? (array) $input($request) : [];
 
        $payload = call_user_func_array($domain, $params);
        return $responder($request, $payload);
    }
 
    abstract protected function getResponder(ActionInterface $action) : callable;
 
    abstract protected function getDomain(ActionInterface $action) : ?callable;
 
    abstract protected function getInput(ActionInterface $action) : ?callable;
}
 
/home/rdc/rdc.refugee/production/vendor/jnjxp/adr/src/Process/AbstractActionHandler.php
namespace Jnjxp\Adr\Process;
 
use Jnjxp\Adr\Action\ActionInterface;
use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\ServerRequestInterface;
use Psr\Http\Server\MiddlewareInterface;
use Psr\Http\Server\RequestHandlerInterface;
 
abstract class AbstractActionHandler implements MiddlewareInterface, RequestHandlerInterface
{
    public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface
    {
        $handler = $this->actionable($request) ? $this : $handler;
        return $handler->handle($request);
    }
 
    public function handle(ServerRequestInterface $request) : ResponseInterface
    {
        $action = $this->getAction($request);
        return $this->act($request, $action);
    }
 
    protected function actionable(ServerRequestInterface $request) : bool
    {
        return (bool) $this->getAction($request);
    }
 
    protected function getAction(ServerRequestInterface $request) : ?ActionInterface
    {
        $action = $request->getAttribute(ActionInterface::class);
        return ($action && $action instanceof ActionInterface) ? $action : null;
    }
 
    protected function act(ServerRequestInterface $request, ActionInterface $action) : ResponseInterface
    {
        $responder = $this->getResponder($action);
 
        if (! $responder) {
            throw new \Exception('No Responder!');
        }
/home/rdc/rdc.refugee/production/vendor/jnjxp/adr/src/Process/AbstractActionHandler.php
<?php
 
declare(strict_types = 1);
 
namespace Jnjxp\Adr\Process;
 
use Jnjxp\Adr\Action\ActionInterface;
use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\ServerRequestInterface;
use Psr\Http\Server\MiddlewareInterface;
use Psr\Http\Server\RequestHandlerInterface;
 
abstract class AbstractActionHandler implements MiddlewareInterface, RequestHandlerInterface
{
    public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface
    {
        $handler = $this->actionable($request) ? $this : $handler;
        return $handler->handle($request);
    }
 
    public function handle(ServerRequestInterface $request) : ResponseInterface
    {
        $action = $this->getAction($request);
        return $this->act($request, $action);
    }
 
    protected function actionable(ServerRequestInterface $request) : bool
    {
        return (bool) $this->getAction($request);
    }
 
    protected function getAction(ServerRequestInterface $request) : ?ActionInterface
    {
        $action = $request->getAttribute(ActionInterface::class);
        return ($action && $action instanceof ActionInterface) ? $action : null;
    }
 
    protected function act(ServerRequestInterface $request, ActionInterface $action) : ResponseInterface
    {
        $responder = $this->getResponder($action);
/home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Next.php
        $this->queue           = clone $queue;
        $this->fallbackHandler = $fallbackHandler;
    }
 
    public function handle(ServerRequestInterface $request): ResponseInterface
    {
        if ($this->queue === null) {
            throw MiddlewarePipeNextHandlerAlreadyCalledException::create();
        }
 
        if ($this->queue->isEmpty()) {
            $this->queue = null;
            return $this->fallbackHandler->handle($request);
        }
 
        $middleware  = $this->queue->dequeue();
        $next        = clone $this; // deep clone is not used intentionally
        $this->queue = null; // mark queue as processed at this nesting level
 
        return $middleware->process($request, $next);
    }
}
 
/home/rdc/rdc.refugee/production/vendor/jnjxp/aura-adr/src/AuraRouteAction.php
 
class AuraRouteAction implements MiddlewareInterface
{
    protected $actionFactory;
 
    public function __construct(ActionFactoryInterface $actionFactory = null)
    {
        $this->actionFactory = $actionFactory ?? new ActionFactory();
    }
 
    public function process(ServerRequestInterface $request, RequestHandlerInterface $handler) : ResponseInterface
    {
        $route = $request->getAttribute(AuraRoute::class);
 
        if ($route && $route instanceof Route) {
            $action = $this->newAction($route);
            $request = $request->withAttribute(ActionInterface::class, $action);
        }
 
        return $handler->handle($request);
    }
 
    protected function newAction(Route $route) : ActionInterface
    {
        return $this->actionFactory->newAction(
            $route->input,
            $route->domain,
            $route->responder
        );
    }
}
 
/home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Next.php
        $this->queue           = clone $queue;
        $this->fallbackHandler = $fallbackHandler;
    }
 
    public function handle(ServerRequestInterface $request): ResponseInterface
    {
        if ($this->queue === null) {
            throw MiddlewarePipeNextHandlerAlreadyCalledException::create();
        }
 
        if ($this->queue->isEmpty()) {
            $this->queue = null;
            return $this->fallbackHandler->handle($request);
        }
 
        $middleware  = $this->queue->dequeue();
        $next        = clone $this; // deep clone is not used intentionally
        $this->queue = null; // mark queue as processed at this nesting level
 
        return $middleware->process($request, $next);
    }
}
 
/home/rdc/rdc.refugee/production/vendor/jnjxp/router/src/Process/AbstractRouteRequest.php
<?php
 
declare(strict_types = 1);
 
namespace Jnjxp\Router\Process;
 
use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\ServerRequestInterface;
use Psr\Http\Server\MiddlewareInterface;
use Psr\Http\Server\RequestHandlerInterface;
 
abstract class AbstractRouteRequest implements MiddlewareInterface
{
    public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface
    {
        $request = $this->match($request)
            ? $this->matched($request)
            : $this->unmatched($request);
 
        return $handler->handle($request);
    }
 
    abstract protected function match(ServerRequestInterface $request) : bool;
 
    abstract protected function matched(ServerRequestInterface $request) : ServerRequestInterface;
 
    protected function unmatched(ServerRequestInterface $request) : ServerRequestInterface
    {
        return $request;
    }
}
 
/home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Next.php
        $this->queue           = clone $queue;
        $this->fallbackHandler = $fallbackHandler;
    }
 
    public function handle(ServerRequestInterface $request): ResponseInterface
    {
        if ($this->queue === null) {
            throw MiddlewarePipeNextHandlerAlreadyCalledException::create();
        }
 
        if ($this->queue->isEmpty()) {
            $this->queue = null;
            return $this->fallbackHandler->handle($request);
        }
 
        $middleware  = $this->queue->dequeue();
        $next        = clone $this; // deep clone is not used intentionally
        $this->queue = null; // mark queue as processed at this nesting level
 
        return $middleware->process($request, $next);
    }
}
 
/home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Middleware/PathMiddlewareDecorator.php
final class PathMiddlewareDecorator implements MiddlewareInterface
{
    private MiddlewareInterface $middleware;
 
    /** @var string Path prefix under which the middleware is segregated.  */
    private string $prefix;
 
    public function __construct(string $prefix, MiddlewareInterface $middleware)
    {
        $this->prefix     = $this->normalizePrefix($prefix);
        $this->middleware = $middleware;
    }
 
    public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface
    {
        $path = $request->getUri()->getPath() ?: '/';
 
        // Current path is shorter than decorator path
        if (strlen($path) < strlen($this->prefix)) {
            return $handler->handle($request);
        }
 
        // Current path does not match decorator path
        if (0 !== stripos($path, $this->prefix)) {
            return $handler->handle($request);
        }
 
        // Skip if match is not at a border ('/' or end)
        $border = $this->getBorder($path);
        if ($border && '/' !== $border) {
            return $handler->handle($request);
        }
 
        // Trim off the part of the url that matches the prefix if it is not / only
        $requestToProcess = $this->prefix !== '/'
            ? $this->prepareRequestWithTruncatedPrefix($request)
            : $request;
 
        // Process our middleware.
        // If the middleware calls on the handler, the handler should be provided
/home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Next.php
        $this->queue           = clone $queue;
        $this->fallbackHandler = $fallbackHandler;
    }
 
    public function handle(ServerRequestInterface $request): ResponseInterface
    {
        if ($this->queue === null) {
            throw MiddlewarePipeNextHandlerAlreadyCalledException::create();
        }
 
        if ($this->queue->isEmpty()) {
            $this->queue = null;
            return $this->fallbackHandler->handle($request);
        }
 
        $middleware  = $this->queue->dequeue();
        $next        = clone $this; // deep clone is not used intentionally
        $this->queue = null; // mark queue as processed at this nesting level
 
        return $middleware->process($request, $next);
    }
}
 
/home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Middleware/PathMiddlewareDecorator.php
final class PathMiddlewareDecorator implements MiddlewareInterface
{
    private MiddlewareInterface $middleware;
 
    /** @var string Path prefix under which the middleware is segregated.  */
    private string $prefix;
 
    public function __construct(string $prefix, MiddlewareInterface $middleware)
    {
        $this->prefix     = $this->normalizePrefix($prefix);
        $this->middleware = $middleware;
    }
 
    public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface
    {
        $path = $request->getUri()->getPath() ?: '/';
 
        // Current path is shorter than decorator path
        if (strlen($path) < strlen($this->prefix)) {
            return $handler->handle($request);
        }
 
        // Current path does not match decorator path
        if (0 !== stripos($path, $this->prefix)) {
            return $handler->handle($request);
        }
 
        // Skip if match is not at a border ('/' or end)
        $border = $this->getBorder($path);
        if ($border && '/' !== $border) {
            return $handler->handle($request);
        }
 
        // Trim off the part of the url that matches the prefix if it is not / only
        $requestToProcess = $this->prefix !== '/'
            ? $this->prepareRequestWithTruncatedPrefix($request)
            : $request;
 
        // Process our middleware.
        // If the middleware calls on the handler, the handler should be provided
/home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Next.php
        $this->queue           = clone $queue;
        $this->fallbackHandler = $fallbackHandler;
    }
 
    public function handle(ServerRequestInterface $request): ResponseInterface
    {
        if ($this->queue === null) {
            throw MiddlewarePipeNextHandlerAlreadyCalledException::create();
        }
 
        if ($this->queue->isEmpty()) {
            $this->queue = null;
            return $this->fallbackHandler->handle($request);
        }
 
        $middleware  = $this->queue->dequeue();
        $next        = clone $this; // deep clone is not used intentionally
        $this->queue = null; // mark queue as processed at this nesting level
 
        return $middleware->process($request, $next);
    }
}
 
/home/rdc/rdc.refugee/production/vendor/jnjxp/auth/src/Middleware/ResumeAuthentication.php
use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\ServerRequestInterface;
use Psr\Http\Server\MiddlewareInterface;
use Psr\Http\Server\RequestHandlerInterface;
 
class ResumeAuthentication implements MiddlewareInterface
{
    private $auth;
    private $resume;
 
    public function __construct(Auth $auth, ResumeService $resume)
    {
        $this->auth = $auth;
        $this->resume = $resume;
    }
 
    public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface
    {
        $request = $this->withAuthentication($request);
        return $handler->handle($request);
    }
 
    protected function withAuthentication(ServerRequestInterface $request) : ServerRequestInterface
    {
        $this->resumeAuth();
        return $request->withAttribute(Auth::class, $this->auth);
    }
 
    protected function resumeAuth() : void
    {
        $this->resume->resume($this->auth);
    }
}
 
/home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Next.php
        $this->queue           = clone $queue;
        $this->fallbackHandler = $fallbackHandler;
    }
 
    public function handle(ServerRequestInterface $request): ResponseInterface
    {
        if ($this->queue === null) {
            throw MiddlewarePipeNextHandlerAlreadyCalledException::create();
        }
 
        if ($this->queue->isEmpty()) {
            $this->queue = null;
            return $this->fallbackHandler->handle($request);
        }
 
        $middleware  = $this->queue->dequeue();
        $next        = clone $this; // deep clone is not used intentionally
        $this->queue = null; // mark queue as processed at this nesting level
 
        return $middleware->process($request, $next);
    }
}
 
/home/rdc/rdc.refugee/production/vendor/middlewares/aura-session/src/AuraSession.php
        $this->attribute = $attribute;
 
        return $this;
    }
 
    /**
     * Process a server request and return a response.
     */
    public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface
    {
        $factory = $this->factory ?: new SessionFactory();
        $session = $factory->newInstance($request->getCookieParams());
 
        if ($this->name !== null) {
            $session->setName($this->name);
        }
 
        $request = $request->withAttribute($this->attribute, $session);
 
        return $handler->handle($request);
    }
}
 
/home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Next.php
        $this->queue           = clone $queue;
        $this->fallbackHandler = $fallbackHandler;
    }
 
    public function handle(ServerRequestInterface $request): ResponseInterface
    {
        if ($this->queue === null) {
            throw MiddlewarePipeNextHandlerAlreadyCalledException::create();
        }
 
        if ($this->queue->isEmpty()) {
            $this->queue = null;
            return $this->fallbackHandler->handle($request);
        }
 
        $middleware  = $this->queue->dequeue();
        $next        = clone $this; // deep clone is not used intentionally
        $this->queue = null; // mark queue as processed at this nesting level
 
        return $middleware->process($request, $next);
    }
}
 
/home/rdc/rdc.refugee/production/vendor/jnjxp/production-host/src/ProductionHost.php
class ProductionHost implements MiddlewareInterface, StatusCodeInterface
{
    protected $responseFactory;
 
    protected $host;
 
    protected $status = self::STATUS_TEMPORARY_REDIRECT;
 
    public function __construct(ResponseFactoryInterface $responseFactory, string $host = null)
    {
        $this->responseFactory = $responseFactory;
        $this->host = $host ? trim($host) : null;
    }
 
    public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface
    {
        if ($this->host) {
            return $this->redirect($request);
        }
        return $handler->handle($request);
    }
 
    protected function redirect(ServerRequestInterface $request) : ResponseInterface
    {
        $uri = $request->getUri()->withHost($this->host);
        return $this->createResponse()->withHeader('Location', (string) $uri);
    }
 
    protected function createResponse() : ResponseInterface
    {
        return $this->responseFactory->createResponse($this->status);
    }
}
 
/home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/Next.php
        $this->queue           = clone $queue;
        $this->fallbackHandler = $fallbackHandler;
    }
 
    public function handle(ServerRequestInterface $request): ResponseInterface
    {
        if ($this->queue === null) {
            throw MiddlewarePipeNextHandlerAlreadyCalledException::create();
        }
 
        if ($this->queue->isEmpty()) {
            $this->queue = null;
            return $this->fallbackHandler->handle($request);
        }
 
        $middleware  = $this->queue->dequeue();
        $next        = clone $this; // deep clone is not used intentionally
        $this->queue = null; // mark queue as processed at this nesting level
 
        return $middleware->process($request, $next);
    }
}
 
/home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php
     * If the pipeline is empty at the time this method is invoked, it will
     * raise an exception.
     *
     * @throws Exception\EmptyPipelineException If no middleware is present in
     *     the instance in order to process the request.
     */
    public function handle(ServerRequestInterface $request): ResponseInterface
    {
        return $this->process($request, new EmptyPipelineHandler(self::class));
    }
 
    /**
     * PSR-15 middleware invocation.
     *
     * Executes the internal pipeline, passing $handler as the "final
     * handler" in cases when the pipeline exhausts itself.
     */
    public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface
    {
        return (new Next($this->pipeline, $handler))->handle($request);
    }
 
    /**
     * Attach middleware to the pipeline.
     */
    public function pipe(MiddlewareInterface $middleware): void
    {
        $this->pipeline->enqueue($middleware);
    }
}
 
/home/rdc/rdc.refugee/production/vendor/laminas/laminas-stratigility/src/MiddlewarePipe.php
    }
 
    /**
     * Handle an incoming request.
     *
     * Attempts to handle an incoming request by doing the following:
     *
     * - Cloning itself, to produce a request handler.
     * - Dequeuing the first middleware in the cloned handler.
     * - Processing the first middleware using the request and the cloned handler.
     *
     * If the pipeline is empty at the time this method is invoked, it will
     * raise an exception.
     *
     * @throws Exception\EmptyPipelineException If no middleware is present in
     *     the instance in order to process the request.
     */
    public function handle(ServerRequestInterface $request): ResponseInterface
    {
        return $this->process($request, new EmptyPipelineHandler(self::class));
    }
 
    /**
     * PSR-15 middleware invocation.
     *
     * Executes the internal pipeline, passing $handler as the "final
     * handler" in cases when the pipeline exhausts itself.
     */
    public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface
    {
        return (new Next($this->pipeline, $handler))->handle($request);
    }
 
    /**
     * Attach middleware to the pipeline.
     */
    public function pipe(MiddlewareInterface $middleware): void
    {
        $this->pipeline->enqueue($middleware);
    }
/home/rdc/rdc.refugee/production/vendor/laminas/laminas-httphandlerrunner/src/RequestHandlerRunner.php
        $this->serverRequestErrorResponseGenerator =
            function (Throwable $exception) use ($serverRequestErrorResponseGenerator) : ResponseInterface {
                return $serverRequestErrorResponseGenerator($exception);
            };
    }
 
    /**
     * Run the application
     */
    public function run() : void
    {
        try {
            $request = ($this->serverRequestFactory)();
        } catch (Throwable $e) {
            // Error in generating the request
            $this->emitMarshalServerRequestException($e);
            return;
        }
 
        $response = $this->handler->handle($request);
 
        $this->emitter->emit($response);
    }
 
    private function emitMarshalServerRequestException(Throwable $exception) : void
    {
        $response = ($this->serverRequestErrorResponseGenerator)($exception);
        $this->emitter->emit($response);
    }
}
 
/home/rdc/rdc.refugee/production/vendor/jnjxp/app/src/App.php
    protected $emitter;
 
    protected $serverRequestCreator;
 
    protected $errorGenerator;
 
    public function __construct(
        EmitterInterface $emitter,
        ServerRequestCreatorInterface $serverRequestCreator,
        callable $errorGenerator
    ) {
        $this->emitter = $emitter;
        $this->serverRequestCreator = $serverRequestCreator;
        $this->errorGenerator = $errorGenerator;
    }
 
    public function run(RequestHandlerInterface $pipe) : void
    {
        $runner = $this->newRunner($pipe);
        $runner->run();
    }
 
    protected function newRunner(RequestHandlerInterface $pipe) : RequestHandlerRunner
    {
        return new RequestHandlerRunner(
            $pipe,
            $this->emitter,
            [$this->serverRequestCreator, 'fromGlobals'],
            $this->errorGenerator
        );
    }
}
 
/home/rdc/rdc.refugee/production/public/index.php
// Delegate static file requests back to the PHP built-in webserver
if (PHP_SAPI === 'cli-server' && $_SERVER['SCRIPT_FILENAME'] !== __FILE__) {
    return false;
}
 
chdir(dirname(__DIR__));
require 'vendor/autoload.php';
require 'config/i18n.php';
 
(function () {
    $container = require 'config/container.php';
 
    if ($container->get('DEBUG')) {
        require 'config/debug.php';
    }
 
    $pipe = (require 'config/pipe.php')($container);
 
    $app = $container->get(App::class);
    $app->run($pipe);
})();
 
/home/rdc/rdc.refugee/production/public/index.php
if (PHP_SAPI === 'cli-server' && $_SERVER['SCRIPT_FILENAME'] !== __FILE__) {
    return false;
}
 
chdir(dirname(__DIR__));
require 'vendor/autoload.php';
require 'config/i18n.php';
 
(function () {
    $container = require 'config/container.php';
 
    if ($container->get('DEBUG')) {
        require 'config/debug.php';
    }
 
    $pipe = (require 'config/pipe.php')($container);
 
    $app = $container->get(App::class);
    $app->run($pipe);
})();
 

Environment & details:

empty
empty
empty
empty
empty
Key Value
TZ America/New_York
REDIRECT_UNIQUE_ID ZgV8NtIQvoi_QfmCq-VTCAAAABI
REDIRECT_HTTP_AUTHORIZATION
REDIRECT_HTTPS on
REDIRECT_SSL_TLS_SNI refugeedevelopmentcenter.org
REDIRECT_HANDLER application/x-httpd-ea-php80
REDIRECT_STATUS 200
UNIQUE_ID ZgV8NtIQvoi_QfmCq-VTCAAAABI
HTTPS on
SSL_TLS_SNI refugeedevelopmentcenter.org
HTTP_ACCEPT */*
HTTP_USER_AGENT claudebot
HTTP_HOST refugeedevelopmentcenter.org
PATH /usr/local/jdk/bin:/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/X11R6/bin:/usr/local/bin:/usr/X11R6/bin:/root/bin:/opt/bin
SERVER_SIGNATURE
SERVER_SOFTWARE Apache
SERVER_NAME refugeedevelopmentcenter.org
SERVER_ADDR 67.227.241.157
SERVER_PORT 443
REMOTE_ADDR 3.81.222.152
DOCUMENT_ROOT /home/rdc/public_html
REQUEST_SCHEME https
CONTEXT_PREFIX /cgi-sys
CONTEXT_DOCUMENT_ROOT /usr/local/cpanel/cgi-sys/
SERVER_ADMIN webmaster@refugeedevelopmentcenter.org
SCRIPT_FILENAME /home/rdc/public_html/index.php
REMOTE_PORT 47138
REDIRECT_URL /index.php
GATEWAY_INTERFACE CGI/1.1
SERVER_PROTOCOL HTTP/1.1
REQUEST_METHOD GET
QUERY_STRING
REQUEST_URI /
SCRIPT_NAME /index.php
ORIG_SCRIPT_FILENAME /usr/local/cpanel/cgi-sys/ea-php80
ORIG_PATH_INFO /index.php
ORIG_PATH_TRANSLATED /home/rdc/public_html/index.php
ORIG_SCRIPT_NAME /cgi-sys/ea-php80
PHP_SELF /index.php
REQUEST_TIME_FLOAT 1711635510.8485
REQUEST_TIME 1711635510
argv Array ( )
argc 0
empty
0. Whoops\Handler\PrettyPageHandler