ruflin/Elastica — pull request #647 by krzaczek (2014-07-07 11:36:29+00:00)
Title: Fix FunstionScore Query random_score without seed bug

Hi,

Quick fix for a random_score without seed. When we want to exetute match all query with random sorting

```php
$Query = new Elastica\Query();
$QueryFS = new Elastica\Query\FunctionScore();
$QueryFS->setRandomScore();
$Query->setQuery($QueryFS);
```

```json
{
"query": {
"function_score": {
"random_score": []
}
}
}
```

This will fail in Elasticsearch because of "random_score": []:

```json
{
"query": {
"function_score": {
"random_score": {}
}
}
}
```

Should be like this :)
Added a test with empty seed to check if it workd in ES.

Pawel