SyliusElasticsearchPlugin
SyliusElasticsearchPlugin copied to clipboard
Fix OptionTaxonsBuilder (option only have taxons from the last product)
Hi.
This PR to correct a regression introduced by commit 48a48ee18d8cf6299e018fb253ad6efad2758dc9
In the OptionTaxonsBuilder, taxons were no longer concatenated, only taxons of the last product of the loop were recorded.
The array_values is there to prevent an error at registration: if the array_unique removes elements from taxons array, array keys are no longer consecutive, which blocks the registration in the ObjectPersister.