diff --git a/composer.json b/composer.json index eda7e650..b352537c 100644 --- a/composer.json +++ b/composer.json @@ -17,7 +17,7 @@ ], "license": "MIT", "require": { - "php": ">=5.5", + "php": ">=7.1", "ext-curl": "*", "ext-json": "*", "ext-simplexml": "*", diff --git a/src/Runtime/ClientObjectCollection.php b/src/Runtime/ClientObjectCollection.php index be5e6ce2..a2f85b5e 100644 --- a/src/Runtime/ClientObjectCollection.php +++ b/src/Runtime/ClientObjectCollection.php @@ -281,10 +281,10 @@ function setProperty($index, $value, $persistChanges = true) /** - * @return Generator|Traversable + * @return Traversable * @throws Exception */ - public function getIterator() + public function getIterator(): Traversable { /** @var ClientObject $item */ foreach ($this->data as $index => $item) { @@ -321,11 +321,12 @@ private function getNextItems(){ * @return boolean * @abstracting ArrayAccess */ - public function offsetExists($offset) + public function offsetExists($offset): bool { return isset($this->data[$offset]); } + #[\ReturnTypeWillChange] /** * Returns the value at specified offset * @@ -348,7 +349,7 @@ public function offsetGet($offset) * @access public * @abstracting ArrayAccess */ - public function offsetSet($offset, $value) + public function offsetSet($offset, $value): void { if (is_null($offset)) { $this->data[] = $value; @@ -364,7 +365,7 @@ public function offsetSet($offset, $value) * @access public * @abstracting ArrayAccess */ - public function offsetUnset($offset) + public function offsetUnset($offset): void { if ($this->offsetExists($offset)) { unset($this->data[$offset]);