foreigner 1.4.1 → 1.4.2

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: 7fc9c2f4af019865f1cf5a5a9ac8bc0676f51c69
4
- data.tar.gz: f5687ab51ea1ae266da097bbbcc2264e67b47023
3
+ metadata.gz: d171f299599a3b127e112d8e3d5fbcf9203fa02e
4
+ data.tar.gz: 300f57bff53bf3445f3dce4c759c86104374d006
5
5
  SHA512:
6
- metadata.gz: ad9df77482992ca92066e60ed7812490b2896b2de4ce24061e07b172427ced547b10c04649c8a51f8e9008fdbdee6f8cd773a41a52b2613e72edaa7b416f79c7
7
- data.tar.gz: 82d8eee97fbfd0c121b4779a7938117e7df5cbb3b4eb12e3d152d384f99bd0f4a69017635070550ff7f1eeb8f0f4f7ba72b947d7960c0d51ea9308cf502a15d2
6
+ metadata.gz: f376ca1b7f10fb7db1bcd75e27b251d136005056deff08136bd1b6dd31e0a747d4f6ccf3689052f5cb0d4739f3c64b925637c3f6d17f59f1976292e924489d49
7
+ data.tar.gz: b97a052321dfe604598ac867cbdab9cdced3e83c5acd264fee9649178d6e934fb1e52dec979497f9aa0f80c92515abaec7cc449e620c51b5f2c717fff3dac8a7
data/README.rdoc CHANGED
@@ -74,6 +74,12 @@ Remove an unwanted foreign key:
74
74
  t.remove_foreign_key :users
75
75
  end
76
76
 
77
+ == Database specific options
78
+
79
+ Database specific options will never be supported by foreigner. You can add them using :options:
80
+
81
+ add_foreign_key(:comments, :posts, options: 'ON UPDATE DEFERRED')
82
+
77
83
  == Foreigner Add-ons
78
84
 
79
85
  * {immigrant}[https://github.com/jenseng/immigrant] - generate a migration that includes all missing foreign keys.
@@ -13,7 +13,7 @@ module Foreigner
13
13
  definition = nil
14
14
  super do |td|
15
15
  definition = td # This is my trick to get the definition
16
- block.call(td)
16
+ block.call(td) unless block.nil?
17
17
  end
18
18
  definition.foreign_keys.each do |to_table, options_list|
19
19
  options_list.each do |options|
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: foreigner
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.1
4
+ version: 1.4.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matthew Higgins
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-04-07 00:00:00.000000000 Z
11
+ date: 2013-06-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activerecord
@@ -93,7 +93,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
93
93
  version: 1.3.5
94
94
  requirements: []
95
95
  rubyforge_project: foreigner
96
- rubygems_version: 2.0.0
96
+ rubygems_version: 2.0.2
97
97
  signing_key:
98
98
  specification_version: 4
99
99
  summary: Foreign Keys for Rails