Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PHP 8.1 deprecated warning #762

Merged
merged 2 commits into from
Dec 5, 2021
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions src/Util/ArrayCollection.php
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ public function count(): int
*
* @phpstan-param int $offset
*/
#[\ReturnTypeWillChange]
colinodell marked this conversation as resolved.
Show resolved Hide resolved
public function offsetExists($offset): bool
{
return \array_key_exists($offset, $this->elements);
Expand All @@ -107,6 +108,7 @@ public function offsetExists($offset): bool
*
* @phpstan-return T|null
*/
#[\ReturnTypeWillChange]
public function offsetGet($offset)
{
return $this->elements[$offset] ?? null;
Expand All @@ -120,6 +122,7 @@ public function offsetGet($offset)
* @phpstan-param int|null $offset
* @phpstan-param T $value
*/
#[\ReturnTypeWillChange]
colinodell marked this conversation as resolved.
Show resolved Hide resolved
public function offsetSet($offset, $value): void
{
if ($offset === null) {
Expand All @@ -136,6 +139,7 @@ public function offsetSet($offset, $value): void
*
* @phpstan-param int $offset
*/
#[\ReturnTypeWillChange]
ElGigi marked this conversation as resolved.
Show resolved Hide resolved
public function offsetUnset($offset): void
{
if (! \array_key_exists($offset, $this->elements)) {
Expand Down