Skip to content
This repository was archived by the owner on Aug 3, 2018. It is now read-only.

Conversation

@einorler
Copy link

I've took some closer look on the case of collection type hinting. Firstly, the setter is mandatory, so sorry for my previous comment, secondly ONGR collection class is deprecated and not recommended anymore, in stead I changed the type hinting to use Doctrine\Common\Collections\Collection interface, because this includes both Doctrine\Common\Collections\ArrayCollection that is recommended by the ONGR collection deprecation message (see here: https://github.com/ongr-io/ElasticsearchBundle/blob/a2642ee9549f3906f2d22d88479364ccc1a542f9/Collection/Collection.php#L19) and ONGR\ElasticsearchBundle\Result\ObjectIterator that ONGR ES bundle uses when lazy loading the results after search.
However, this is a potential place to pay close attention to in the future, because I contacted the maintainer of the ONGR project and I was informed that this is a known issue in ONGR ES bundle and will be attended to in the comming months.

Closes #95

@einorler einorler force-pushed the fix-document-type-hinting branch 3 times, most recently from 74120a2 to a45e9d7 Compare October 8, 2018 09:39
@einorler einorler force-pushed the fix-document-type-hinting branch from a45e9d7 to c6640d6 Compare October 8, 2018 13:39
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Error when rendering results

1 participant