monsieurbiz / SyliusSearchPlugin

A search plugin using Elasticsearch for Sylius
MIT License
45 stars 38 forks source link

Do not send filter to ES if they do not exists in Sylius #210

Open maximehuran opened 3 months ago

maximehuran commented 3 months ago

Exemple /taxons/my-taxon?attributes[toto][]=Test

If attribute toto does not exists or it exists but is not filterable I will have a 500

[2024-06-05T15:09:36.177871+00:00] request.CRITICAL: Uncaught PHP Exception Elastica\Exception\ResponseException: "failed to create query: [nested] failed to find nested object under path [attributes.toto] [index: monsieurbiz_product_fr_2024-06-05-150918] [reason: all shards failed]" at /app/tests/apps/sylius/vendor/ruflin/elastica/src/Transport/Http.php line 178