-
-
Notifications
You must be signed in to change notification settings - Fork 910
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
Doctrine's Collection not recognized as array #2176
Comments
PHPStan is correct here. You really cannot pass You also really shouldn't check for objects using
Your code is broken a lot. |
Ok, you are right: I've just refactored with Rector and it changed my code this way... I didn't really think about it in a hurry: I've to come back to the old code... Thank you! |
Anyway the code is not broken as they are entities and so are always the same object once fetched from the database 😅 |
Yes, if the email is an entity then it’s fine but let’s hope this
requirement is always met 😊
On Mon, 3 Jun 2019 at 17:14, Adamo Crespi ***@***.***> wrote:
Anyway the code is not broken as they are entities and so are always the
same object once fetched from the database 😅
—
You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub
<#2176?email_source=notifications&email_token=AAAZTOGURXCE3XQ6OL3GXJTPYUYN3A5CNFSM4HSI63I2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODWZXHTI#issuecomment-498299853>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAAZTOESKCCN6J25PRG57WDPYUYN3ANCNFSM4HSI63IQ>
.
--
Ondřej Mirtes
|
I have this code:
The errors I receive are those:
Lines refers to the two methods
OrderVoter::isBillee()
andOrderVoter::isConsignee()
.I've tried to reproduce (for what is possible) the issue here:
https://phpstan.org/r/b7dfa46b-ba40-4f10-9720-093c0258ff19
Any ideas about how to solve those errors?
I'm using version 0.11.6 of PHPStan.
The text was updated successfully, but these errors were encountered: