mirror of
https://github.com/n3w/helpers-cli-input.git
synced 2025-12-19 12:43:23 +00:00
Fixed InputCollection::getArgumentsByIndex() so it returns NULL if the index does not exist instead of throwing an E_NOTICE message
This commit is contained in:
parent
8d3141c79f
commit
25f3fb8014
1 changed files with 1 additions and 1 deletions
|
|
@ -77,7 +77,7 @@ class InputCollection
|
|||
|
||||
public function getArgumentsByIndex(int $index): ?AbstractInputType
|
||||
{
|
||||
return $this->arguments[$index];
|
||||
return $this->arguments[$index] ?? null;
|
||||
}
|
||||
|
||||
public function getArguments(): array
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue