note 124324 added to arrayaccess.offsetget
| From: | MartinQ@php.net | Date: | Tue, 22 Oct 2019 21:28:46 +0000 |
| Subject: | note 124324 added to arrayaccess.offsetget | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-212750@lists.php.net to get a copy of this message | ||
As of PHP 7, offsetExists($offset) must return a TRUE value in order for offsetGet($offset) to be
called, otherwise offsetGet($offset) will just return NULL. This was not the case in PHP 5, so if
your code suddenly stops working upon upgrade to PHP 7, make sure offsetExists() returns sensible
values.
----
Server IP: 208.43.231.9
Probable Submitter: 185.85.3.195 (proxied: 95.90.38.146)
----
Manual Page -- http://php.net/manual/en/arrayaccess.offsetget.php
Edit -- https://master.php.net/note/edit/124324
Del: integrated -- https://master.php.net/note/delete/124324/integrated
Del: useless -- https://master.php.net/note/delete/124324/useless
Del: bad code -- https://master.php.net/note/delete/124324/bad+code
Del: spam -- https://master.php.net/note/delete/124324/spam
Del: non-english -- https://master.php.net/note/delete/124324/non-english
Del: in docs -- https://master.php.net/note/delete/124324/in+docs
Del: other reasons-- https://master.php.net/note/delete/124324
Reject -- https://master.php.net/note/reject/124324
Search -- https://master.php.net/manage/user-notes.php