*/
public function __construct($file, int $status = 200, array $headers = [], bool $public = true, string $contentDisposition = null, bool $autoEtag = false, bool $autoLastModified = true)
{
parent::__construct(null, $status, $headers);
$this->setFile($file, $contentDisposition, $autoEtag, $autoLastModified);
if ($public) {
$this->setPublic();
}
}
* @param string|null $disposition
* @return \Symfony\Component\HttpFoundation\BinaryFileResponse
*/
public function download($file, $name = null, array $headers = [], $disposition = 'attachment')
{
$response = new BinaryFileResponse($file, 200, $headers, true, $disposition);
if (! is_null($name)) {
return $response->setContentDisposition($disposition, $name, $this->fallbackName($name));
}
// since the object we're given was already a fully instantiated object.
$parameters = [$passable, $stack];
}
$carry = method_exists($pipe, $this->method)
? $pipe->{$this->method}(...$parameters)
: $pipe(...$parameters);
return $this->handleCarry($carry);
} catch (Throwable $e) {
return $this->handleException($passable, $e);
// since the object we're given was already a fully instantiated object.
$parameters = [$passable, $stack];
}
$carry = method_exists($pipe, $this->method)
? $pipe->{$this->method}(...$parameters)
: $pipe(...$parameters);
return $this->handleCarry($carry);
} catch (Throwable $e) {
return $this->handleException($passable, $e);
// since the object we're given was already a fully instantiated object.
$parameters = [$passable, $stack];
}
$carry = method_exists($pipe, $this->method)
? $pipe->{$this->method}(...$parameters)
: $pipe(...$parameters);
return $this->handleCarry($carry);
} catch (Throwable $e) {
return $this->handleException($passable, $e);
// since the object we're given was already a fully instantiated object.
$parameters = [$passable, $stack];
}
$carry = method_exists($pipe, $this->method)
? $pipe->{$this->method}(...$parameters)
: $pipe(...$parameters);
return $this->handleCarry($carry);
} catch (Throwable $e) {
return $this->handleException($passable, $e);
// since the object we're given was already a fully instantiated object.
$parameters = [$passable, $stack];
}
$carry = method_exists($pipe, $this->method)
? $pipe->{$this->method}(...$parameters)
: $pipe(...$parameters);
return $this->handleCarry($carry);
} catch (Throwable $e) {
return $this->handleException($passable, $e);
if ($this->manager->shouldBlock() ||
($request->route() instanceof Route && $request->route()->locksFor())) {
return $this->handleRequestWhileBlocking($request, $session, $next);
} else {
return $this->handleStatefulRequest($request, $session, $next);
}
}
/**
* Handle the given request within session state.
// since the object we're given was already a fully instantiated object.
$parameters = [$passable, $stack];
}
$carry = method_exists($pipe, $this->method)
? $pipe->{$this->method}(...$parameters)
: $pipe(...$parameters);
return $this->handleCarry($carry);
} catch (Throwable $e) {
return $this->handleException($passable, $e);
// since the object we're given was already a fully instantiated object.
$parameters = [$passable, $stack];
}
$carry = method_exists($pipe, $this->method)
? $pipe->{$this->method}(...$parameters)
: $pipe(...$parameters);
return $this->handleCarry($carry);
} catch (Throwable $e) {
return $this->handleException($passable, $e);
// since the object we're given was already a fully instantiated object.
$parameters = [$passable, $stack];
}
$carry = method_exists($pipe, $this->method)
? $pipe->{$this->method}(...$parameters)
: $pipe(...$parameters);
return $this->handleCarry($carry);
} catch (Throwable $e) {
return $this->handleException($passable, $e);
// since the object we're given was already a fully instantiated object.
$parameters = [$passable, $stack];
}
$carry = method_exists($pipe, $this->method)
? $pipe->{$this->method}(...$parameters)
: $pipe(...$parameters);
return $this->handleCarry($carry);
} catch (Throwable $e) {
return $this->handleException($passable, $e);
// since the object we're given was already a fully instantiated object.
$parameters = [$passable, $stack];
}
$carry = method_exists($pipe, $this->method)
? $pipe->{$this->method}(...$parameters)
: $pipe(...$parameters);
return $this->handleCarry($carry);
} catch (Throwable $e) {
return $this->handleException($passable, $e);
// since the object we're given was already a fully instantiated object.
$parameters = [$passable, $stack];
}
$carry = method_exists($pipe, $this->method)
? $pipe->{$this->method}(...$parameters)
: $pipe(...$parameters);
return $this->handleCarry($carry);
} catch (Throwable $e) {
return $this->handleException($passable, $e);
// since the object we're given was already a fully instantiated object.
$parameters = [$passable, $stack];
}
$carry = method_exists($pipe, $this->method)
? $pipe->{$this->method}(...$parameters)
: $pipe(...$parameters);
return $this->handleCarry($carry);
} catch (Throwable $e) {
return $this->handleException($passable, $e);
*/
public function handle($request, Closure $next)
{
// Check if we're dealing with CORS and if we should handle it
if (! $this->shouldRun($request)) {
return $next($request);
}
// For Preflight, return the Preflight response
if ($this->cors->isPreflightRequest($request)) {
$response = $this->cors->handlePreflightRequest($request);
// since the object we're given was already a fully instantiated object.
$parameters = [$passable, $stack];
}
$carry = method_exists($pipe, $this->method)
? $pipe->{$this->method}(...$parameters)
: $pipe(...$parameters);
return $this->handleCarry($carry);
} catch (Throwable $e) {
return $this->handleException($passable, $e);
public function handle(Request $request, Closure $next)
{
$request::setTrustedProxies([], $this->getTrustedHeaderNames()); // Reset trusted proxies between requests
$this->setTrustedProxyIpAddresses($request);
return $next($request);
}
/**
* Sets the trusted proxies on the request to the value of trustedproxy.proxies
*
// since the object we're given was already a fully instantiated object.
$parameters = [$passable, $stack];
}
$carry = method_exists($pipe, $this->method)
? $pipe->{$this->method}(...$parameters)
: $pipe(...$parameters);
return $this->handleCarry($carry);
} catch (Throwable $e) {
return $this->handleException($passable, $e);
FileNotFoundException |
---|
Symfony\Component\HttpFoundation\File\Exception\FileNotFoundException: The file "" does not exist at /var/www/vhosts/jetstax.com/httpdocs/vendor/symfony/http-foundation/File/File.php:36 at Symfony\Component\HttpFoundation\File\File->__construct('') (/var/www/vhosts/jetstax.com/httpdocs/vendor/symfony/http-foundation/BinaryFileResponse.php:93) at Symfony\Component\HttpFoundation\BinaryFileResponse->setFile('', 'attachment', false, true) (/var/www/vhosts/jetstax.com/httpdocs/vendor/symfony/http-foundation/BinaryFileResponse.php:51) at Symfony\Component\HttpFoundation\BinaryFileResponse->__construct('', 200, array(), true, 'attachment') (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/ResponseFactory.php:165) at Illuminate\Routing\ResponseFactory->download('') (/var/www/vhosts/jetstax.com/httpdocs/app/Http/Controllers/Web/About/PrivacyPolicyController.php:40) at App\Http\Controllers\Web\About\PrivacyPolicyController->getDownload(object(Request), 'es') (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/Controller.php:54) at Illuminate\Routing\Controller->callAction('getDownload', array(object(Request), 'locale' => 'es')) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/ControllerDispatcher.php:45) at Illuminate\Routing\ControllerDispatcher->dispatch(object(Route), object(PrivacyPolicyController), 'getDownload') (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/Route.php:254) at Illuminate\Routing\Route->runController() (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/Route.php:197) at Illuminate\Routing\Route->run() (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/Router.php:693) at Illuminate\Routing\Router->Illuminate\Routing\{closure}(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:128) at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/silber/page-cache/src/Middleware/CacheResponse.php:38) at Silber\PageCache\Middleware\CacheResponse->handle(object(Request), object(Closure)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167) at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/app/Http/Middleware/SetLocale.php:32) at App\Http\Middleware\SetLocale->handle(object(Request), object(Closure)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167) at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/Middleware/SubstituteBindings.php:50) at Illuminate\Routing\Middleware\SubstituteBindings->handle(object(Request), object(Closure)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167) at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/VerifyCsrfToken.php:78) at Illuminate\Foundation\Http\Middleware\VerifyCsrfToken->handle(object(Request), object(Closure)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167) at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/View/Middleware/ShareErrorsFromSession.php:49) at Illuminate\View\Middleware\ShareErrorsFromSession->handle(object(Request), object(Closure)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167) at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Session/Middleware/StartSession.php:121) at Illuminate\Session\Middleware\StartSession->handleStatefulRequest(object(Request), object(Store), object(Closure)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Session/Middleware/StartSession.php:63) at Illuminate\Session\Middleware\StartSession->handle(object(Request), object(Closure)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167) at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Cookie/Middleware/AddQueuedCookiesToResponse.php:37) at Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse->handle(object(Request), object(Closure)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167) at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Cookie/Middleware/EncryptCookies.php:67) at Illuminate\Cookie\Middleware\EncryptCookies->handle(object(Request), object(Closure)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167) at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:103) at Illuminate\Pipeline\Pipeline->then(object(Closure)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/Router.php:695) at Illuminate\Routing\Router->runRouteWithinStack(object(Route), object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/Router.php:670) at Illuminate\Routing\Router->runRoute(object(Request), object(Route)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/Router.php:636) at Illuminate\Routing\Router->dispatchToRoute(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/Router.php:625) at Illuminate\Routing\Router->dispatch(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:166) at Illuminate\Foundation\Http\Kernel->Illuminate\Foundation\Http\{closure}(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:128) at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php:21) at Illuminate\Foundation\Http\Middleware\TransformsRequest->handle(object(Request), object(Closure)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167) at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php:21) at Illuminate\Foundation\Http\Middleware\TransformsRequest->handle(object(Request), object(Closure)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167) at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ValidatePostSize.php:27) at Illuminate\Foundation\Http\Middleware\ValidatePostSize->handle(object(Request), object(Closure)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167) at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/PreventRequestsDuringMaintenance.php:86) at Illuminate\Foundation\Http\Middleware\PreventRequestsDuringMaintenance->handle(object(Request), object(Closure)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167) at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/fruitcake/laravel-cors/src/HandleCors.php:37) at Fruitcake\Cors\HandleCors->handle(object(Request), object(Closure)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167) at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/fideloper/proxy/src/TrustProxies.php:57) at Fideloper\Proxy\TrustProxies->handle(object(Request), object(Closure)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167) at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:103) at Illuminate\Pipeline\Pipeline->then(object(Closure)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:141) at Illuminate\Foundation\Http\Kernel->sendRequestThroughRouter(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:110) at Illuminate\Foundation\Http\Kernel->handle(object(Request)) (/var/www/vhosts/jetstax.com/httpdocs/public/index.php:52) |