has_constant 0.7.0 → 0.7.1
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/has_constant.gemspec +1 -1
- data/lib/has_constant/orm/mongoid.rb +2 -1
- metadata +3 -3
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.7.
|
1
|
+
0.7.1
|
data/has_constant.gemspec
CHANGED
@@ -24,7 +24,8 @@ module HasConstant
|
|
24
24
|
|
25
25
|
class_eval do
|
26
26
|
unless fields.map(&:first).include?(singular.to_s)
|
27
|
-
|
27
|
+
type = (options[:as] == :array) ? Array : Integer
|
28
|
+
field singular.to_sym, { :type => type }.merge(options)
|
28
29
|
end
|
29
30
|
|
30
31
|
index singular.to_sym, :background => true if options[:index]
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: has_constant
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 1
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 7
|
9
|
-
-
|
10
|
-
version: 0.7.
|
9
|
+
- 1
|
10
|
+
version: 0.7.1
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- mattbeedle
|