mongoid-autoinc 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/autoinc.rb +2 -2
- data/lib/autoinc/version.rb +1 -1
- metadata +2 -2
data/lib/autoinc.rb
CHANGED
@@ -45,8 +45,8 @@ module Mongoid
|
|
45
45
|
def increment!(field, options)
|
46
46
|
scope_key = options[:scope] ? send(options[:scope]) : nil
|
47
47
|
write_attribute(
|
48
|
-
field.to_sym,
|
49
|
-
|
48
|
+
field.to_sym, Mongoid::Autoinc::Incrementor.new(
|
49
|
+
self.class.model_name, field, scope_key).inc
|
50
50
|
)
|
51
51
|
end
|
52
52
|
|
data/lib/autoinc/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mongoid-autoinc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -11,7 +11,7 @@ authors:
|
|
11
11
|
autorequire:
|
12
12
|
bindir: bin
|
13
13
|
cert_chain: []
|
14
|
-
date: 2012-09-
|
14
|
+
date: 2012-09-24 00:00:00.000000000 Z
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
17
17
|
name: mongoid
|