mirror of
https://github.com/linuxserver/Heimdall.git
synced 2025-12-11 01:14:06 +09:00
Updates to vendors etc
This commit is contained in:
21
vendor/symfony/http-foundation/RequestStack.php
vendored
21
vendor/symfony/http-foundation/RequestStack.php
vendored
@@ -26,15 +26,23 @@ class RequestStack
|
||||
*/
|
||||
private array $requests = [];
|
||||
|
||||
/**
|
||||
* @param Request[] $requests
|
||||
*/
|
||||
public function __construct(array $requests = [])
|
||||
{
|
||||
foreach ($requests as $request) {
|
||||
$this->push($request);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Pushes a Request on the stack.
|
||||
*
|
||||
* This method should generally not be called directly as the stack
|
||||
* management should be taken care of by the application itself.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function push(Request $request)
|
||||
public function push(Request $request): void
|
||||
{
|
||||
$this->requests[] = $request;
|
||||
}
|
||||
@@ -106,4 +114,11 @@ class RequestStack
|
||||
|
||||
throw new SessionNotFoundException();
|
||||
}
|
||||
|
||||
public function resetRequestFormats(): void
|
||||
{
|
||||
static $resetRequestFormats;
|
||||
$resetRequestFormats ??= \Closure::bind(static fn () => self::$formats = null, null, Request::class);
|
||||
$resetRequestFormats();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user