\Zendesk\API\Resources\Core\Search::find has wrong parameter type annotation
georgms opened this issue · 2 comments
georgms commented
\Zendesk\API\Resources\Core\Search::find parameter $query
has the type annotation null
while it should clearly be string
:
I came across this while validating a project with PHPStan.
pointybeard commented
Hit this one while running PHPStan also. Quick fix is to add a line like this to phpstan.neon.dist
in the ignoreErrors
segment:
ignoreErrors:
- '#Parameter \#1 \$query of method Zendesk\\API\\Resources\\Core\\Search::find\(\) expects null, string given.#'
Proper fix, of course, is to change * @param null $query
to * @param string $query
as mentioned.
pointybeard commented
Just popped through PR #486 for this one.