mirror of
https://github.com/danog/MadelineProto.git
synced 2024-11-27 11:34:41 +01:00
MemoryArray undefined offset fix
This commit is contained in:
parent
6cf1ef504f
commit
8254360d2f
@ -28,7 +28,7 @@ class MemoryArray extends \ArrayIterator implements DbArray
|
|||||||
|
|
||||||
public function offsetGet($offset): Promise
|
public function offsetGet($offset): Promise
|
||||||
{
|
{
|
||||||
return call(fn() => parent::offsetGet($offset));
|
return call(fn() => parent::offsetExists($offset) ? parent::offsetGet($offset) : null);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function offsetUnset($offset): Promise
|
public function offsetUnset($offset): Promise
|
||||||
|
Loading…
Reference in New Issue
Block a user