update patch 1
This commit is contained in:
@@ -28,7 +28,6 @@ use Symfony\Component\HttpFoundation\Session\SessionBagInterface;
|
||||
class MockArraySessionStorage implements SessionStorageInterface
|
||||
{
|
||||
protected string $id = '';
|
||||
protected string $name;
|
||||
protected bool $started = false;
|
||||
protected bool $closed = false;
|
||||
protected array $data = [];
|
||||
@@ -39,9 +38,10 @@ class MockArraySessionStorage implements SessionStorageInterface
|
||||
*/
|
||||
protected array $bags = [];
|
||||
|
||||
public function __construct(string $name = 'MOCKSESSID', ?MetadataBag $metaBag = null)
|
||||
{
|
||||
$this->name = $name;
|
||||
public function __construct(
|
||||
protected string $name = 'MOCKSESSID',
|
||||
?MetadataBag $metaBag = null,
|
||||
) {
|
||||
$this->setMetadataBag($metaBag);
|
||||
}
|
||||
|
||||
@@ -133,7 +133,7 @@ class MockArraySessionStorage implements SessionStorageInterface
|
||||
public function getBag(string $name): SessionBagInterface
|
||||
{
|
||||
if (!isset($this->bags[$name])) {
|
||||
throw new \InvalidArgumentException(sprintf('The SessionBagInterface "%s" is not registered.', $name));
|
||||
throw new \InvalidArgumentException(\sprintf('The SessionBagInterface "%s" is not registered.', $name));
|
||||
}
|
||||
|
||||
if (!$this->started) {
|
||||
|
||||
Reference in New Issue
Block a user