gummi 0.3.9 → 0.3.10

Sign up to get free protection for your applications and to get access to all the features.
@@ -18,7 +18,12 @@ module Gummi
18
18
  @facets ||= begin
19
19
  result = {}
20
20
  search_result.facets.each do |(name, content)|
21
- result[name] = Hash[content.terms.map(&:values)]
21
+ case content['_type']
22
+ when 'terms'
23
+ result[name] = Hash[content.terms.map(&:values)]
24
+ when 'statistical'
25
+ result[name] = Hash[content.map(&:values)]
26
+ end
22
27
  end
23
28
  Hashie::Mash.new result
24
29
  end
@@ -51,4 +56,4 @@ module Gummi
51
56
  end
52
57
  end
53
58
  end
54
- end
59
+ end
data/lib/gummi/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Gummi
2
- VERSION = '0.3.9'
2
+ VERSION = '0.3.10'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gummi
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.9
4
+ version: 0.3.10
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-02-18 00:00:00.000000000 Z
12
+ date: 2014-02-25 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: virtus
@@ -311,3 +311,4 @@ test_files:
311
311
  - spec/support/models/db/ship.rb
312
312
  - spec/support/models/people.rb
313
313
  - spec/support/models/person.rb
314
+ has_rdoc: