mongoid_auto_increment_id 0.6.3 → 0.6.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 434cdc91ec6eec48ebf757721283ea86f955ee66
4
- data.tar.gz: 365e9a0e9f1836102ace998ae13ad136776bd628
3
+ metadata.gz: 449618cc87c1c15cb4a4687c16ab0fbfa0f0b329
4
+ data.tar.gz: 0543aa1040bb9d5779741d1af69b7eb6fdc14398
5
5
  SHA512:
6
- metadata.gz: 1b1b9085d50672f3c0fc382382ae4552c381aef716dce8f436a07eb8f74a6913edc2065e0e2960747e8b1b1a54b48b953f71f390480d2b877dd1f09c4c975dbb
7
- data.tar.gz: d08f4a3c2a8dbae3742086541b3e03ca0e20e686bb71349329647ae05fe8f7b263150656f556576d960e253f61c4c8925da4a37fba582da2513037277e6b7f21
6
+ metadata.gz: 652b684be9f30fc88696f73f7acb9e18864cb95af69b7e2fffa97e87ab6e2797d135dcc79d9c16fc45c368b873983aeab509bbc449481ffb629cd2ee6d95fb00
7
+ data.tar.gz: 9c02e0384d385ed420996c7e25e1e5516cc9af8cd445d777139f19809d84639b27d1fa9c91140519827b691cffd36d252c2b41c89a02166fd40b6cae71588571
data/README.md CHANGED
@@ -17,7 +17,7 @@ gem 'mongoid_auto_increment_id', "0.6.1"
17
17
  gem 'mongoid_auto_increment_id', "0.6.2"
18
18
 
19
19
  # Mongoid 4.0.0+
20
- gem 'mongoid_auto_increment_id', "0.6.3"
20
+ gem 'mongoid_auto_increment_id', "0.6.4"
21
21
  ```
22
22
 
23
23
  ## USAGE
@@ -12,10 +12,12 @@ module Mongoid
12
12
  end
13
13
 
14
14
  module Document
15
- # define Integer for id field
16
- included do
17
- Mongoid.register_model(self)
18
- field :_id, :type => Integer, :overwrite => true
15
+ def self.included(base)
16
+ base.class_eval do
17
+ # define Integer for id field
18
+ Mongoid.register_model(self)
19
+ field :_id, :type => Integer, :overwrite => true
20
+ end
19
21
  end
20
22
 
21
23
  # hack id nil when Document.new
metadata CHANGED
@@ -1,33 +1,33 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mongoid_auto_increment_id
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.3
4
+ version: 0.6.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jason Lee
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-10-30 00:00:00.000000000 Z
11
+ date: 2014-04-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: mongoid
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - '>='
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
19
  version: 3.1.0
20
- - - <
20
+ - - "<"
21
21
  - !ruby/object:Gem::Version
22
22
  version: 4.1.0
23
23
  type: :runtime
24
24
  prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
26
26
  requirements:
27
- - - '>='
27
+ - - ">="
28
28
  - !ruby/object:Gem::Version
29
29
  version: 3.1.0
30
- - - <
30
+ - - "<"
31
31
  - !ruby/object:Gem::Version
32
32
  version: 4.1.0
33
33
  description: This gem for change Mongoid id field as Integer like MySQL.
@@ -37,8 +37,8 @@ executables: []
37
37
  extensions: []
38
38
  extra_rdoc_files: []
39
39
  files:
40
- - lib/mongoid_auto_increment_id.rb
41
40
  - README.md
41
+ - lib/mongoid_auto_increment_id.rb
42
42
  homepage: https://github.com/huacnlee/mongoid_auto_increment_id
43
43
  licenses: []
44
44
  metadata: {}
@@ -48,17 +48,17 @@ require_paths:
48
48
  - lib
49
49
  required_ruby_version: !ruby/object:Gem::Requirement
50
50
  requirements:
51
- - - '>='
51
+ - - ">="
52
52
  - !ruby/object:Gem::Version
53
53
  version: '0'
54
54
  required_rubygems_version: !ruby/object:Gem::Requirement
55
55
  requirements:
56
- - - '>='
56
+ - - ">="
57
57
  - !ruby/object:Gem::Version
58
58
  version: '0'
59
59
  requirements: []
60
60
  rubyforge_project:
61
- rubygems_version: 2.0.3
61
+ rubygems_version: 2.2.2
62
62
  signing_key:
63
63
  specification_version: 4
64
64
  summary: Override id field with MySQL like auto increment for Mongoid