See: https://github.com/ongr-io/ElasticsearchBundle/pull/868#pullrequestreview-459878231 I'm not sure what the idea was behind that logic, so I cannot propose an alternative at this time.