meta_where 0.9.5 → 0.9.6
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG +3 -0
- data/Gemfile +2 -7
- data/VERSION +1 -1
- data/lib/meta_where/builder.rb +2 -2
- data/meta_where.gemspec +2 -2
- metadata +3 -3
data/CHANGELOG
CHANGED
data/Gemfile
CHANGED
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.9.
|
1
|
+
0.9.6
|
data/lib/meta_where/builder.rb
CHANGED
@@ -30,7 +30,7 @@ module MetaWhere
|
|
30
30
|
elsif value.is_a?(MetaWhere::Condition)
|
31
31
|
association = parent.is_a?(Symbol) ? nil : @join_dependency.find_join_association(column, parent)
|
32
32
|
value.to_predicate(self, association || column)
|
33
|
-
elsif value.is_a?(Array) && value.all? {|v| v.respond_to?(:to_predicate)}
|
33
|
+
elsif value.is_a?(Array) && !value.empty? && value.all? {|v| v.respond_to?(:to_predicate)}
|
34
34
|
association = parent.is_a?(Symbol) ? nil : @join_dependency.find_join_association(column, parent)
|
35
35
|
value.map {|val| val.to_predicate(self, association || column)}
|
36
36
|
else
|
@@ -81,4 +81,4 @@ module MetaWhere
|
|
81
81
|
end
|
82
82
|
|
83
83
|
end
|
84
|
-
end
|
84
|
+
end
|
data/meta_where.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{meta_where}
|
8
|
-
s.version = "0.9.
|
8
|
+
s.version = "0.9.6"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Ernie Miller"]
|
12
|
-
s.date = %q{2010-09-
|
12
|
+
s.date = %q{2010-09-30}
|
13
13
|
s.description = %q{
|
14
14
|
MetaWhere offers the ability to call any Arel predicate methods
|
15
15
|
(with a few convenient aliases) on your Model's attributes instead
|
metadata
CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
|
|
5
5
|
segments:
|
6
6
|
- 0
|
7
7
|
- 9
|
8
|
-
-
|
9
|
-
version: 0.9.
|
8
|
+
- 6
|
9
|
+
version: 0.9.6
|
10
10
|
platform: ruby
|
11
11
|
authors:
|
12
12
|
- Ernie Miller
|
@@ -14,7 +14,7 @@ autorequire:
|
|
14
14
|
bindir: bin
|
15
15
|
cert_chain: []
|
16
16
|
|
17
|
-
date: 2010-09-
|
17
|
+
date: 2010-09-30 00:00:00 -04:00
|
18
18
|
default_executable:
|
19
19
|
dependencies:
|
20
20
|
- !ruby/object:Gem::Dependency
|