earth 0.0.32 → 0.0.33

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/lib/earth.rb CHANGED
@@ -2,6 +2,7 @@ require 'active_record'
2
2
  require 'cohort_scope'
3
3
  require 'earth/base'
4
4
  require 'earth/conversions_ext'
5
+ require 'earth/active_record_ext'
5
6
  require 'earth/inflectors'
6
7
  require 'data_miner'
7
8
  require 'falls_back_on'
@@ -0,0 +1,8 @@
1
+ ::ActiveRecord::Base.class_eval do
2
+ def self.run_data_miner_on_belongs_to_associations
3
+ reflect_on_all_associations(:belongs_to).each do |a|
4
+ next if a.options[:polymorphic]
5
+ a.klass.run_data_miner!
6
+ end
7
+ end
8
+ end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: earth
3
3
  version: !ruby/object:Gem::Version
4
- hash: 95
4
+ hash: 93
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 32
10
- version: 0.0.32
9
+ - 33
10
+ version: 0.0.33
11
11
  platform: ruby
12
12
  authors:
13
13
  - Seamus Abshere
@@ -17,7 +17,7 @@ autorequire:
17
17
  bindir: bin
18
18
  cert_chain: []
19
19
 
20
- date: 2010-09-07 00:00:00 -04:00
20
+ date: 2010-09-07 00:00:00 -05:00
21
21
  default_executable:
22
22
  dependencies:
23
23
  - !ruby/object:Gem::Dependency
@@ -28,7 +28,7 @@ dependencies:
28
28
  requirements:
29
29
  - - ">="
30
30
  - !ruby/object:Gem::Version
31
- hash: -1848230024
31
+ hash: 299253624
32
32
  segments:
33
33
  - 3
34
34
  - 0
@@ -220,6 +220,7 @@ files:
220
220
  - LICENSE
221
221
  - README.markdown
222
222
  - lib/earth.rb
223
+ - lib/earth/active_record_ext.rb
223
224
  - lib/earth/air.rb
224
225
  - lib/earth/air/aircraft.rb
225
226
  - lib/earth/air/aircraft/data_miner.rb