Skip to content

Commit

Permalink
Merge branch '1.0' into 1.x
Browse files Browse the repository at this point in the history
  • Loading branch information
dvesh3 committed Aug 3, 2023
2 parents 349de4c + 28dcb14 commit fe6189d
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
10 changes: 5 additions & 5 deletions src/IndexService/Config/AbstractConfig.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,23 +26,23 @@ abstract class AbstractConfig implements ConfigInterface
{
protected string $tenantName;

protected array $attributeConfig;
protected array $attributeConfig = [];

protected array $searchAttributeConfig;
protected array $searchAttributeConfig = [];

protected ?AttributeFactory $attributeFactory = null;

protected array $attributes = [];

protected array $searchAttributes;
protected array $searchAttributes = [];

protected array $filterTypes;
protected array $filterTypes = [];

protected ?WorkerInterface $tenantWorker = null;

protected ?array $filterTypeConfig = null;

protected array $options;
protected array $options = [];

/**
* @param array[]|Attribute[] $attributes
Expand Down
6 changes: 3 additions & 3 deletions src/IndexService/Config/ElasticSearch.php
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,9 @@ class ElasticSearch extends AbstractConfig implements MockupConfigInterface, Ela
public function __construct(
AttributeFactory $attributeFactory,
string $tenantName,
array $attributes,
array $searchAttributes,
array $filterTypes,
array $attributes = [],
array $searchAttributes = [],
array $filterTypes = [],
array $options = [],
iterable $synonymProviders = []
) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1145,7 +1145,7 @@ protected function convertBucketValues(array $bucket): array
$data['key_as_string'] = $bucket['key_as_string'];
} elseif (is_array($reverseAggregationBucket) && array_key_exists('doc_count', $reverseAggregationBucket)) { // reverse aggregation
$data['reverse_count'] = $reverseAggregationBucket['doc_count'];
} elseif (is_array($subAggregationBuckets['buckets'])) { // sub aggregations
} elseif(is_array($subAggregationBuckets) && isset($subAggregationBuckets['buckets'])) { // sub aggregations
foreach ($subAggregationBuckets['buckets'] as $bucket) {
$data[$subAggregationField][] = $this->convertBucketValues($bucket);
}
Expand Down

0 comments on commit fe6189d

Please sign in to comment.