We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a3719ca commit 1f79a62Copy full SHA for 1f79a62
src/Http/SessionSection.php
@@ -17,9 +17,6 @@
17
*/
18
class SessionSection implements \IteratorAggregate, \ArrayAccess
19
{
20
- public bool $warnOnUndefined = false;
21
-
22
23
/**
24
* Do not call directly. Use Session::getSection().
25
@@ -112,10 +109,6 @@ public function &__get(string $name): mixed
112
109
trigger_error("Reading from \$session->$name is deprecated, use \$session->get('$name') instead", E_USER_DEPRECATED);
113
110
$this->session->autoStart(true);
114
111
$data = &$this->getData();
115
- if ($this->warnOnUndefined && !array_key_exists($name, $data ?? [])) {
116
- trigger_error("The variable '$name' does not exist in session section");
117
- }
118
119
return $data[$name];
120
}
121
0 commit comments