Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Phpstan complains on parameters mismatch #134

Open
bochkarev-artem opened this issue May 25, 2022 · 1 comment
Open

Phpstan complains on parameters mismatch #134

bochkarev-artem opened this issue May 25, 2022 · 1 comment

Comments

@bochkarev-artem
Copy link

After updating phpstan to version 1.7.1 it now gives an error for this usage:
Parameter #1 $params of method GoCardlessPro\Services\PaymentsService::create() expects string, array<string, array<string, array<string, string>|int|string>> given.

I see that create method can receive array, string[mixed] $params An associative array for any params. But i guess phpstan sees only string. Will you consider to annotate your method differently?

* @param string[mixed] $params An associative array for any params

@noplanman
Copy link
Contributor

Type hinting in general can definitely be improved in this library.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants