switchman 1.5.14 → 1.5.15

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: 991a3392b5b0202a9bcaf8029a7bb7c103ec1643
4
- data.tar.gz: 3687768e39078beaf8fff5e1cdf2aae1cc4b2c31
3
+ metadata.gz: bd0d33eb675d2b10b4c3f4c58cd70664fffc02d9
4
+ data.tar.gz: ceb9f08769064d7c046b79c2d4570680d835302a
5
5
  SHA512:
6
- metadata.gz: 36845dd017c674600b9d7ec1d66ba5a8fe9732dcb7597d5c0490a6bbfbcceeb8def4a413941895f48a8b541f5487a33fd850b475a03c1f38a7b2b7012be0cc05
7
- data.tar.gz: 9b6774b94a699618901e82f020f3ce61b0e54dff581e947f9e738472db2637d81c65f0afc2ef5abdb709a0e1cd238a7fac677d805a25bd602144ebe9733061c9
6
+ metadata.gz: bb26c88cfc2df081bdfc3d3ca9e2f3fb0c683f5a1ea5f9174229de2f0f4a6b2c23397f061711db2c6a02a5a718f1d91c1ffda9c627f3264cd443d7d4697587ed
7
+ data.tar.gz: d8d0e4ce64c6e80d4f8df2c47f770947eaeb2f0e10b06e34ca265ee2642d5b87d5a03ec9a900a1d75f3c3b45c1f4285cd0e8074d8ccfbc050d1b1d10ddc0b4d5
@@ -228,7 +228,7 @@ module Switchman
228
228
  def sharded_primary_key?(relation, column)
229
229
  column = column.to_s
230
230
  return column == 'id' if relation.model == ::ActiveRecord::Base
231
- relation.model.primary_key == column
231
+ relation.model.primary_key == column && relation.model.integral_id?
232
232
  end
233
233
 
234
234
  def source_shard_for_foreign_key(relation, column)
@@ -1,3 +1,3 @@
1
1
  module Switchman
2
- VERSION = "1.5.14"
2
+ VERSION = "1.5.15"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: switchman
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.14
4
+ version: 1.5.15
5
5
  platform: ruby
6
6
  authors:
7
7
  - Cody Cutrer