Skip to content
This repository has been archived by the owner on Nov 22, 2017. It is now read-only.

Use stats for fields with 2 levels. #350

Open
wants to merge 1 commit into
base: kibana-ruby
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/kelastic.rb
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ def collect_item_attributes(h,field)
field = field.gsub("\.",".properties.")
types = h.sort_by { |k,v| v }[0][1]
types.each do | type |
r << field.split(".",3).inject(type[1]['properties']) { |hash, key|
r << field.split(".",5).inject(type[1]['properties']) { |hash, key|
if defined?hash[key]
hash[key]
end
Expand Down