Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fix bug introduced by search.

  • Loading branch information...
commit bccb4db3d32ed7f1300fa4bdefd8a700e591548b 1 parent 789bcbb
Marius Seritan authored committed
Showing with 1 addition and 1 deletion.
  1. +1 −1  lib/rails_admin/adapters/mongoid.rb
View
2  lib/rails_admin/adapters/mongoid.rb
@@ -218,7 +218,7 @@ def criteria_for_options(options)
sort = options.delete(:sort)
sort_reverse = options.delete(:sort_reverse)
# detect a LIKE condition
- criteria = if options[:conditions][0][' LIKE ']
+ criteria = if options && options[:conditions] && options[:conditions][0][' LIKE ']
criteria_for_search(options)
else
model.where(options)
Please sign in to comment.
Something went wrong with that request. Please try again.