Skip to content

Commit

Permalink
Merge fa3ba0a into f71bab3
Browse files Browse the repository at this point in the history
  • Loading branch information
deguif committed Oct 27, 2020
2 parents f71bab3 + fa3ba0a commit 95b0800
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
2 changes: 2 additions & 0 deletions src/Exception/ElasticsearchException.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
* Elasticsearch exception.
*
* @author Ian Babrou <ibobrik@gmail.com>
*
* @deprecated since version 5.2.0
*/
class ElasticsearchException extends \Exception implements ExceptionInterface
{
Expand Down
4 changes: 3 additions & 1 deletion src/Exception/ResponseException.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,12 @@ public function getResponse(): Response

/**
* Returns elasticsearch exception.
*
* @deprecated since version 7.1.0, use the "getResponse()::getFullError()" method instead.
*/
public function getElasticsearchException(): ElasticsearchException
{
trigger_deprecation('ruflin/elastica', '7.1.0', 'The "%s()" method is deprecated, use "%s::getResponse()::getFullError()" instead. It will be removed in 8.0.', __METHOD__, __CLASS__);
trigger_deprecation('ruflin/elastica', '7.1.0', 'The "%s()" method is deprecated, use "getResponse()::getFullError()" instead. It will be removed in 8.0.', __METHOD__);

$response = $this->getResponse();

Expand Down
2 changes: 1 addition & 1 deletion src/Query/Match.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
*
* @author Nicolas Ruflin <spam@ruflin.com>
*
* @deprecated Use MatchQuery instead. From PHP 8 match is reserved word and this class will be removed in further Elastica releases
* @deprecated since version 7.1.0, use the MatchQuery class instead.
*/
class Match extends MatchQuery
{
Expand Down
4 changes: 2 additions & 2 deletions src/QueryBuilder/DSL/Aggregation.php
Original file line number Diff line number Diff line change
Expand Up @@ -233,11 +233,11 @@ public function global(string $name): GlobalAggregation
}

/**
* @deprecated since Elastica 7.0.1, use the "global()" method instead.
* @deprecated since version 7.1.0, use the "global()" method instead.
*/
public function global_agg(string $name): GlobalAggregation
{
trigger_deprecation('ruflin/elastica', '7.1.0', 'The "%s()" method is deprecated, use global() instead. It will be removed in 8.0.', __METHOD__);
trigger_deprecation('ruflin/elastica', '7.1.0', 'The "%s()" method is deprecated, use "global()" instead. It will be removed in 8.0.', __METHOD__);

return $this->global($name);
}
Expand Down

0 comments on commit 95b0800

Please sign in to comment.