From 1a365e77dfb8825136626202b1df462731b42060 Mon Sep 17 00:00:00 2001 From: Pierre Schmitz Date: Sun, 16 Aug 2015 08:22:05 +0200 Subject: Update to MediaWiki 1.25.2 --- .../Aggregation/AbstractSimpleAggregation.php | 33 ++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 vendor/ruflin/elastica/lib/Elastica/Aggregation/AbstractSimpleAggregation.php (limited to 'vendor/ruflin/elastica/lib/Elastica/Aggregation/AbstractSimpleAggregation.php') diff --git a/vendor/ruflin/elastica/lib/Elastica/Aggregation/AbstractSimpleAggregation.php b/vendor/ruflin/elastica/lib/Elastica/Aggregation/AbstractSimpleAggregation.php new file mode 100644 index 00000000..af7c1940 --- /dev/null +++ b/vendor/ruflin/elastica/lib/Elastica/Aggregation/AbstractSimpleAggregation.php @@ -0,0 +1,33 @@ +setParam('field', $field); + } + + /** + * Set a script for this aggregation + * @param string|Script $script + * @return AbstractSimpleAggregation + */ + public function setScript($script) + { + if ($script instanceof Script) { + $this->setParam('params', $script->getParams()); + $script = $script->getScript(); + } + return $this->setParam('script', $script); + } +} \ No newline at end of file -- cgit v1.2.2