diff --git a/.travis.yml b/.travis.yml index 0466c6a6..c4465ad5 100644 --- a/.travis.yml +++ b/.travis.yml @@ -8,7 +8,7 @@ php: - 7.4 env: global: - - ES_VERSION=6.7.1 ES_DOWNLOAD_URL=https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-${ES_VERSION}.tar.gz + - ES_VERSION=6.8.2 ES_DOWNLOAD_URL=https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-${ES_VERSION}.tar.gz install: - wget ${ES_DOWNLOAD_URL} - tar -xzf elasticsearch-${ES_VERSION}.tar.gz diff --git a/composer.json b/composer.json index 403c686d..1ebacdc8 100644 --- a/composer.json +++ b/composer.json @@ -12,11 +12,11 @@ ], "require": { "php": "^7.0", - "symfony/serializer": "^3.0|^4.0|^5.0", - "paragonie/random_compat": "*" + "symfony/serializer": "^3.0|^4.0", + "paragonie/random_compat": "*", + "elasticsearch/elasticsearch": "^6.0" }, "require-dev": { - "elasticsearch/elasticsearch": "^6.0", "phpunit/phpunit": "^7.0", "squizlabs/php_codesniffer": "^3.0" }, diff --git a/src/SearchEndpoint/AggregationsEndpoint.php b/src/SearchEndpoint/AggregationsEndpoint.php index 3e035f43..079a6a5d 100644 --- a/src/SearchEndpoint/AggregationsEndpoint.php +++ b/src/SearchEndpoint/AggregationsEndpoint.php @@ -27,7 +27,7 @@ class AggregationsEndpoint extends AbstractSearchEndpoint /** * {@inheritdoc} */ - public function normalize(NormalizerInterface $normalizer, string $format = null, array $context = []) + public function normalize(NormalizerInterface $normalizer, $format = null, array $context = []) { $output = []; if (count($this->getAll()) > 0) { diff --git a/src/SearchEndpoint/HighlightEndpoint.php b/src/SearchEndpoint/HighlightEndpoint.php index aa57b3d7..f2b8d8e9 100644 --- a/src/SearchEndpoint/HighlightEndpoint.php +++ b/src/SearchEndpoint/HighlightEndpoint.php @@ -37,7 +37,7 @@ class HighlightEndpoint extends AbstractSearchEndpoint /** * {@inheritdoc} */ - public function normalize(NormalizerInterface $normalizer, string $format = null, array $context = []) + public function normalize(NormalizerInterface $normalizer, $format = null, array $context = []) { if ($this->highlight) { return $this->highlight->toArray(); diff --git a/src/SearchEndpoint/InnerHitsEndpoint.php b/src/SearchEndpoint/InnerHitsEndpoint.php index 8428bd88..f1562fe6 100644 --- a/src/SearchEndpoint/InnerHitsEndpoint.php +++ b/src/SearchEndpoint/InnerHitsEndpoint.php @@ -27,7 +27,7 @@ class InnerHitsEndpoint extends AbstractSearchEndpoint /** * {@inheritdoc} */ - public function normalize(NormalizerInterface $normalizer, string $format = null, array $context = []) + public function normalize(NormalizerInterface $normalizer, $format = null, array $context = []) { $output = []; if (count($this->getAll()) > 0) { diff --git a/src/SearchEndpoint/PostFilterEndpoint.php b/src/SearchEndpoint/PostFilterEndpoint.php index de3e263c..6055b7ed 100644 --- a/src/SearchEndpoint/PostFilterEndpoint.php +++ b/src/SearchEndpoint/PostFilterEndpoint.php @@ -26,7 +26,7 @@ class PostFilterEndpoint extends QueryEndpoint /** * {@inheritdoc} */ - public function normalize(NormalizerInterface $normalizer, string $format = null, array $context = []) + public function normalize(NormalizerInterface $normalizer, $format = null, array $context = []) { if (!$this->getBool()) { return null; diff --git a/src/SearchEndpoint/QueryEndpoint.php b/src/SearchEndpoint/QueryEndpoint.php index b7626910..6212b05d 100644 --- a/src/SearchEndpoint/QueryEndpoint.php +++ b/src/SearchEndpoint/QueryEndpoint.php @@ -39,7 +39,7 @@ class QueryEndpoint extends AbstractSearchEndpoint implements OrderedNormalizerI /** * {@inheritdoc} */ - public function normalize(NormalizerInterface $normalizer, string $format = null, array $context = []) + public function normalize(NormalizerInterface $normalizer, $format = null, array $context = []) { if (!$this->filtersSet && $this->hasReference('filter_query')) { /** @var BuilderInterface $filter */ diff --git a/src/SearchEndpoint/SortEndpoint.php b/src/SearchEndpoint/SortEndpoint.php index cd00bb2f..2461c858 100644 --- a/src/SearchEndpoint/SortEndpoint.php +++ b/src/SearchEndpoint/SortEndpoint.php @@ -26,7 +26,7 @@ class SortEndpoint extends AbstractSearchEndpoint /** * {@inheritdoc} */ - public function normalize(NormalizerInterface $normalizer, string $format = null, array $context = []) + public function normalize(NormalizerInterface $normalizer, $format = null, array $context = []) { $output = []; diff --git a/src/SearchEndpoint/SuggestEndpoint.php b/src/SearchEndpoint/SuggestEndpoint.php index 6d292239..2e2e16ac 100644 --- a/src/SearchEndpoint/SuggestEndpoint.php +++ b/src/SearchEndpoint/SuggestEndpoint.php @@ -27,7 +27,7 @@ class SuggestEndpoint extends AbstractSearchEndpoint /** * {@inheritdoc} */ - public function normalize(NormalizerInterface $normalizer, string $format = null, array $context = []) + public function normalize(NormalizerInterface $normalizer, $format = null, array $context = []) { $output = []; if (count($this->getAll()) > 0) { diff --git a/src/Serializer/Normalizer/CustomReferencedNormalizer.php b/src/Serializer/Normalizer/CustomReferencedNormalizer.php index 99ca63db..6cd24a8e 100644 --- a/src/Serializer/Normalizer/CustomReferencedNormalizer.php +++ b/src/Serializer/Normalizer/CustomReferencedNormalizer.php @@ -26,7 +26,7 @@ class CustomReferencedNormalizer extends CustomNormalizer /** * {@inheritdoc} */ - public function normalize($object, string $format = null, array $context = []) + public function normalize($object, $format = null, array $context = []) { $object->setReferences($this->references); $data = parent::normalize($object, $format, $context); @@ -38,7 +38,7 @@ public function normalize($object, string $format = null, array $context = []) /** * {@inheritdoc} */ - public function supportsNormalization($data, string $format = null) + public function supportsNormalization($data, $format = null) { return $data instanceof AbstractNormalizable; } diff --git a/src/Serializer/OrderedSerializer.php b/src/Serializer/OrderedSerializer.php index 7bc51118..bcbb9c3d 100644 --- a/src/Serializer/OrderedSerializer.php +++ b/src/Serializer/OrderedSerializer.php @@ -22,7 +22,7 @@ class OrderedSerializer extends Serializer /** * {@inheritdoc} */ - public function normalize($data, string $format = null, array $context = []) + public function normalize($data, $format = null, array $context = []) { return parent::normalize( is_array($data) ? $this->order($data) : $data,