Skip to content

Commit 4ae0a95

Browse files
author
Rebrov
committed
fix getAll methodˆ
1 parent 1b3fb14 commit 4ae0a95

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

src/AbstractRESTResource.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,8 @@ public function __call($name, $arguments)
124124
&& \is_string($arguments[1])
125125
&& \is_int($arguments[2])) {
126126
$options = $arguments;
127+
} elseif ('getAll' === $name) {
128+
$options = $arguments;
127129
} else {
128130
$options = [];
129131
}

src/ResourceDescription/ContactsResource.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ public function getHttpMethod(string $actionName, array $options = []): ?string
8181

8282
public function getResponseModelType(string $actionName)
8383
{
84-
if (\in_array($actionName, ['list', 'getWithoutCustomField'])) {
84+
if (\in_array($actionName, ['list', 'getWithoutCustomField', 'getAll'])) {
8585
return sprintf('array<%s>', Contact::class);
8686
}
8787

0 commit comments

Comments
 (0)