diff --git a/src/Elasticsearch/Namespaces/IndicesNamespace.php b/src/Elasticsearch/Namespaces/IndicesNamespace.php index 2ad6b1585..ea20f2c2d 100644 --- a/src/Elasticsearch/Namespaces/IndicesNamespace.php +++ b/src/Elasticsearch/Namespaces/IndicesNamespace.php @@ -248,6 +248,7 @@ public function shrink($params = array()) { $index = $this->extractArgument($params, 'index'); $target = $this->extractArgument($params, 'target'); + $body = $this->extractArgument($params, 'body'); /** @var callback $endpointBuilder */ $endpointBuilder = $this->endpoints; @@ -255,7 +256,8 @@ public function shrink($params = array()) /** @var \Elasticsearch\Endpoints\Indices\Shrink $endpoint */ $endpoint = $endpointBuilder('Indices\Shrink'); $endpoint->setIndex($index) - ->setTarget($target); + ->setTarget($target) + ->setBody($body); return $this->performRequest($endpoint); }