We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
I see that we had the issue with the falsy value caused by the misuse of array_filter function.
array_filter
For my case i am using this mapping
/** * @var string * @ES\Property(type="text", settings={"index"=false}) */ private $url;
The actual result which is not expected (please ignore the nested type)
{ "properties": { "url": { "type": "text" } } }
The expected result should be
{ "properties": { "url": { "type": "text", "index": false #<-----this_is_what_we_want } } }
I believe the root cause was this line https://github.com/ongr-io/ElasticsearchBundle/blob/v6.2.2/Mapping/DocumentParser.php#L169
When changing it to this, it works fine
$mapping[$annotation->getName() ?? Caser::snake($name)] = array_filter( $fieldMapping, function ($value) { return null !== $value; } );
- PHP version: 7.3 - Elasticsearch version: 6.x - Bundle version: 6.x - Symfony version: 5.x
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I see that we had the issue with the falsy value caused by the misuse of
array_filter
function.For my case i am using this mapping
The actual result which is not expected (please ignore the nested type)
The expected result should be
I believe the root cause was this line https://github.com/ongr-io/ElasticsearchBundle/blob/v6.2.2/Mapping/DocumentParser.php#L169
When changing it to this, it works fine
The text was updated successfully, but these errors were encountered: