shiftable 0.5.0 → 0.5.1

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: 678fdd1fc65199227c201ecd4346e4c0019c78747d949ac9b4dcba8b38158c24
4
- data.tar.gz: 3f527ed0b2e70a2e677b006320b3e667d0512ccfcacc5bb76232129b9f37c6d0
3
+ metadata.gz: 8bad3e2f27677202648655a227fa9f251a595910db9146c9fdb72952657053d3
4
+ data.tar.gz: 481fede6aa751831cec5c19fe8849b61b081f51cfd4e5aa0a7522ecbb31b38bf
5
5
  SHA512:
6
- metadata.gz: c281d086eabfbce50dcd9f3098374656a8c7536b0ce1d5e21d5262c6e205172f90930aa7120a747904d6599313c235adba0bc5487011fa7b5df0e8c90af9157b
7
- data.tar.gz: 217eb1fb303dbc45ccb962bddbff8c4dc246b20351b1f1f2312b9e4ea8c4db7a90360c089b040f0276e544a38193d01feb1728bd6f3949dfe849509a12d38a64
6
+ metadata.gz: 050f4afb2b1ad1e81cd9209dfee0a0f1270745a02bfea84dcaff3914794349c4e6b53b01fb21873731ad05693ae0d02639ee3ade2a0f0d1b5b103fc30952e362
7
+ data.tar.gz: 5bfc201b247b3082a0a1836c164133f73f59f317de9664934f08bc28a6b3d00140e2c2a3fe0ed7da2a0450fcabb67c66eb28e28c3787403517eadd28fb8d8114
data/CHANGELOG.md CHANGED
@@ -12,6 +12,11 @@
12
12
  ### Removed
13
13
 
14
14
 
15
+ ## [0.5.1] - 2021-11-12
16
+ ### Fixed
17
+
18
+ - Documentation typos in README
19
+
15
20
  ## [0.5.0] - 2021-11-12
16
21
  ### Added
17
22
 
data/README.md CHANGED
@@ -153,7 +153,7 @@ class SpaceTreatySignature < ActiveRecord::Base
153
153
  # )
154
154
  extend Shiftable::Collection.new(
155
155
  belongs_to: :signatory, has_many: :space_treaty_signature,
156
- polymorphic_type: "SpaceFederation",
156
+ polymorphic: { type: "SpaceFederation", as: :signatory },
157
157
  method_prefix: "space_federation_",
158
158
  before_shift: lambda { |shifting_rel:, shift_to:, shift_from:|
159
159
  # Each item in shifting_rel is an instance of the class where Shiftable::Collection is defined,
@@ -171,7 +171,7 @@ class SpaceFederation < ActiveRecord::Base
171
171
  has_many :treaty_planets, class_name: "Planet", through: :space_treaty_signatures, as: :signatory
172
172
  has_many :treaty_stations, class_name: "SpaceStation", through: :space_treaty_signatures, as: :signatory
173
173
  def assimilate_from(other_federation)
174
- SpaceTreatySignature.space_federation_shift_cx(shift_to: self, shift_from: other_federation)
174
+ SpaceTreatySignature.space_federation_shift_pcx(shift_to: self, shift_from: other_federation)
175
175
  end
176
176
  end
177
177
 
@@ -189,7 +189,7 @@ class SpaceStation < ActiveRecord::Base
189
189
  has_many :treaty_federations, class_name: "SpaceFederation", through: :space_treaty_signatures, as: :signatory
190
190
  has_many :treaty_planets, class_name: "Planet", through: :space_treaty_signatures, as: :signatory
191
191
  end
192
- ```#<--rubocop/md-->#<--rubocop/md-->`
192
+ ```
193
193
 
194
194
  ### Complete example
195
195
 
@@ -241,7 +241,7 @@ class SpaceTreatySignature < ActiveRecord::Base
241
241
  belongs_to :signatory, polymorphic: true
242
242
  extend Shiftable::Collection.new(
243
243
  belongs_to: :signatory, has_many: :space_treaty_signatures,
244
- polymorphic_type: "SpaceFederation",
244
+ polymorphic: { type: "SpaceFederation", as: :signatory },
245
245
  method_prefix: "space_federation_"
246
246
  )
247
247
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Shiftable
4
- VERSION = "0.5.0"
4
+ VERSION = "0.5.1"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: shiftable
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.5.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Peter Boling