Skip to content

Commit

Permalink
Merge pull request #16 from cavvia/dev
Browse files Browse the repository at this point in the history
remove unneeded bool_filter code
  • Loading branch information
dblock authored Jan 25, 2017
2 parents 78ebbca + 134b112 commit 5639fe1
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions lib/estella/query.rb
Original file line number Diff line number Diff line change
Expand Up @@ -109,17 +109,5 @@ def add_filters
end
end
end

def bool_filter(field, param)
if param
{ term: { field => true } }
elsif !param.nil?
{ term: { field => false } }
end
end

def add_bool_filter(field, param)
must bool_filter(field, param) if bool_filter(field, param)
end
end
end

0 comments on commit 5639fe1

Please sign in to comment.