brick 1.0.182 → 1.0.183

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
  SHA256:
3
- metadata.gz: 390cb3f8a466f1d94c0e8e7472017753fb09f8c9909a71134545e25b47edfb21
4
- data.tar.gz: 9398ee17aa8a5b8741adf784ebde9421f6419f93a421ec0ba5893f028b192383
3
+ metadata.gz: 78c32d3b30786e5d03ea9cbc0decf042a808270fb7dc43809da36604d3fa8586
4
+ data.tar.gz: 9735242b6967624178bc3ed2d65368f3530fe172a27e1a7554e505d4a3ba9854
5
5
  SHA512:
6
- metadata.gz: 75c2d9f206d58f5296862fcdec776b3a5daa82e2c7405ff3fa46bf386e61cfac39ddf9cf55d7ab3eb54ddf23434c5086fd99e6d9eca0543ed63d9946892ea140
7
- data.tar.gz: 1818e986519622fd6c51c25e0153e003a476c7e823f14ff4cc9aabdf4cfb1adae7fe8f67ff1e9ca1a181694e028aa3b0c985afad8ab88b5c1d839be3aba70ed0
6
+ metadata.gz: 7fed1dc602b5fa4420670c7cfb923870b8fefa6ae14d61ce8a72597bc29054130eb7c871de9fcfdc06af3a7fd9b7588f4ac2267b846ba92f3c49c0b233d8a640
7
+ data.tar.gz: c613f387851e56aaa32256cd2d8170293323df3d8f86de200bf1c350b025b516df386ce608c4bef6c8d5905d377a354cf72dc949eda617b2188ed37c441ebbc9
@@ -5,7 +5,7 @@ module Brick
5
5
  module VERSION
6
6
  MAJOR = 1
7
7
  MINOR = 0
8
- TINY = 182
8
+ TINY = 183
9
9
 
10
10
  # PRE is nil unless it's a pre-release (beta, RC, etc.)
11
11
  PRE = nil
data/lib/brick.rb CHANGED
@@ -282,7 +282,7 @@ module Brick
282
282
  next
283
283
  end
284
284
  else
285
- this_fks = this_fk.is_a?(Array) ? this_fk : [this_fk.to_s]
285
+ this_fks = (this_fk = a.foreign_key).is_a?(Array) ? this_fk.uniq : [this_fk.to_s]
286
286
  if !a.options.key?(:as) && (this_fks - a.klass.column_names).length.positive?
287
287
  options = ", #{a.options.map { |k, v| "#{k.inspect} => #{v.inspect}" }.join(', ')}" if a.options.present?
288
288
  puts "WARNING: Model #{model.name} has this association:
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: brick
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.182
4
+ version: 1.0.183
5
5
  platform: ruby
6
6
  authors:
7
7
  - Lorin Thwaits
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-10-14 00:00:00.000000000 Z
11
+ date: 2023-10-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activerecord