Skip to content

Commit

Permalink
fix(metadata): no deprecation when elasticsearch is null
Browse files Browse the repository at this point in the history
  • Loading branch information
dannyvw committed Mar 24, 2023
1 parent de7c0b7 commit ecdab94
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public function create(string $resourceClass): ResourceMetadataCollection
: 'You will have to remove it when upgrading to v4';
trigger_deprecation('api-platform/core', '3.1', sprintf('Setting "elasticsearch" in Operation is deprecated. %s', $solution));
}
if ($this->hasIndices($operation)) {
if (null !== $elasticsearch && $this->hasIndices($operation)) {
$operation = $operation->withElasticsearch(true);
}

Expand Down

0 comments on commit ecdab94

Please sign in to comment.