removing unused sanitization code in mongoid spec
This commit is contained in:
parent
f759ab7e54
commit
bd9480cb51
|
@ -11,24 +11,6 @@ if ENV["MODEL_ADAPTER"] == "mongoid"
|
||||||
include Mongoid::Document
|
include Mongoid::Document
|
||||||
|
|
||||||
referenced_in :mongoid_category
|
referenced_in :mongoid_category
|
||||||
|
|
||||||
class << self
|
|
||||||
protected
|
|
||||||
|
|
||||||
def sanitize_sql(hash_cond)
|
|
||||||
hash_cond
|
|
||||||
end
|
|
||||||
|
|
||||||
def sanitize_hash(hash)
|
|
||||||
hash.map do |name, value|
|
|
||||||
if Hash === value
|
|
||||||
sanitize_hash(value).map{|cond| "#{name}.#{cond}"}
|
|
||||||
else
|
|
||||||
"#{name}=#{value}"
|
|
||||||
end
|
|
||||||
end.flatten
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
Mongoid.configure do |config|
|
Mongoid.configure do |config|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user