co-elastic-query 1.0.6 → 1.0.7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a252f8562630b0a0d3241d4073ee19a8ed90145b
4
- data.tar.gz: f5392cc5b35e261ecf9a973da1a40efb7623d640
3
+ metadata.gz: b028d67268c8c71064fe202176e956d442ab2995
4
+ data.tar.gz: dce3b78197073eeaa55fba4333b956024129e1c1
5
5
  SHA512:
6
- metadata.gz: 0cfbfbecd60ddc4e7f89b269afa0a4d25a5ebe22d188afa1978183786802c52419b10a69aec9ae9f35ed1442f161e819e81f47064d91b6ac001b3ae10836a0f5
7
- data.tar.gz: abf22384ebb70f7c5b030179b023126e2a10697f8fb063f14da1b06fccd0c1752c752f034f868ab89f148d94dafd877ee50aa9beb2ff1beb46a1242be563fc99
6
+ metadata.gz: ce3289a8806236685b556b5eab70e3a744f1122c666ca15c6d71a7ea163b9d6d0739186a132ce014b9c87185274240153fb51a0eff8929aa5b468f87b5122c6e
7
+ data.tar.gz: 59237b3a94abf844c095ff9ef7ede5bf5d115da4612ed02d92f5189b735380bafc82cb5ecad6b41d1f5e3773f6fa0ed00a9234a433acaac1ce3bce7b598dac65
@@ -286,7 +286,7 @@ class Elastic
286
286
  HITS = 'hits'.freeze
287
287
  TOTAL = 'total'.freeze
288
288
  ID = '_id'.freeze
289
- SCORE = '_score'.freeze
289
+ SCORE = ['_score'.freeze]
290
290
  INDEX = (ENV['ELASTIC_INDEX'] || 'default').freeze
291
291
 
292
292
  def initialize(klass, opts = {})
@@ -334,8 +334,7 @@ class Elastic
334
334
  def generate_body(builder)
335
335
  opt = builder.build
336
336
 
337
- sort = opt[:sort] || []
338
- sort << SCORE
337
+ sort = (opt[:sort] || []) + SCORE
339
338
 
340
339
  queries = opt[:queries] || []
341
340
  queries.unshift(opt[:query])
@@ -1,3 +1,3 @@
1
1
  module CoElasticQuery
2
- VERSION = "1.0.6"
2
+ VERSION = "1.0.7"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: co-elastic-query
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.6
4
+ version: 1.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stephen von Takach
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2015-08-27 00:00:00.000000000 Z
12
+ date: 2015-09-09 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bundler