Mercurial > hg > isophonics-drupal-site
diff vendor/symfony/http-foundation/Session/SessionBagProxy.php @ 16:c2387f117808
Routine composer update
author | Chris Cannam |
---|---|
date | Tue, 10 Jul 2018 15:07:59 +0100 |
parents | 1fec387a4317 |
children | 129ea1e6d783 |
line wrap: on
line diff
--- a/vendor/symfony/http-foundation/Session/SessionBagProxy.php Thu Apr 26 11:26:54 2018 +0100 +++ b/vendor/symfony/http-foundation/Session/SessionBagProxy.php Tue Jul 10 15:07:59 2018 +0100 @@ -20,13 +20,13 @@ { private $bag; private $data; - private $hasBeenStarted; + private $usageIndex; - public function __construct(SessionBagInterface $bag, array &$data, &$hasBeenStarted) + public function __construct(SessionBagInterface $bag, array &$data, &$usageIndex) { $this->bag = $bag; $this->data = &$data; - $this->hasBeenStarted = &$hasBeenStarted; + $this->usageIndex = &$usageIndex; } /** @@ -34,6 +34,8 @@ */ public function getBag() { + ++$this->usageIndex; + return $this->bag; } @@ -42,6 +44,8 @@ */ public function isEmpty() { + ++$this->usageIndex; + return empty($this->data[$this->bag->getStorageKey()]); } @@ -58,7 +62,7 @@ */ public function initialize(array &$array) { - $this->hasBeenStarted = true; + ++$this->usageIndex; $this->data[$this->bag->getStorageKey()] = &$array; $this->bag->initialize($array); @@ -77,6 +81,8 @@ */ public function clear() { + ++$this->usageIndex; + return $this->bag->clear(); } }