active_type 2.6.0 → 2.6.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
  SHA256:
3
- metadata.gz: 970684d2b41b30fef4a53c0d4ab29ef2d25a7ca391be73a21295cfd07ef527a5
4
- data.tar.gz: 0d0b34b0af58796b9cb6d877470894da5484a1658ef3a4704d603b9cbbf45c57
3
+ metadata.gz: 8e6ed5e81a70acff0be214e9a3a653f4142fac9bd1a4a5840810d440da0c53c0
4
+ data.tar.gz: f1634c346152775f229004f5a77b2c98c107f1a530219060fb7e1ca6d38f5b6c
5
5
  SHA512:
6
- metadata.gz: 24e437dc4e496c086c1789e01a0e47571541f9557f8585e822c53b9e5001b62d676a9ec1476ac075c6a1cd014584c1121a1d898cfeb09cb2a9b7ce1f20deb190
7
- data.tar.gz: 34a47671ac54c98464fd2ecdfd1d8ca528e2b43e29d571688e7a63d0d60b3f8848192d16c536fe16159ae1fc340ca37debc19a765786b335957c0fdb41c68e4e
6
+ metadata.gz: 71a7ba9a1d620cdd2ee58bfbcb1c3b087ebcaec36d4f4d984f434d959420df9da30eeb5b1eef035aebb9c76986a2578e4c9a6fba0fda3258bcce063faf2f5329
7
+ data.tar.gz: 382be4ad591537dda5e19e58256c5479a1a12bd488d9939e697f3c68292746c2d8c23e518a0d7e3f9db48db4246007a7adaf1b778cdc29e92c58890715143cca
data/CHANGELOG.md CHANGED
@@ -2,9 +2,19 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file.
4
4
 
5
+ ## 2.6.2 (2025-02-12)
6
+
7
+ * Fixed: Issue with `ActiveType::Object` when using an optional `belongs_to` on a virtual attribute.
8
+ Thanks to @kyanagi.
9
+
10
+ ## 2.6.1 (2025-01-17)
11
+
12
+ * Fixed: Issue with `ActiveType::Object` when using has_many on Rails 7.2.
13
+ Thanks to @corableus.
14
+
5
15
  ## 2.6.0 (2024-12-20)
6
16
 
7
- * Dropped support for Rails < 6 and Ruby < 2.7.
17
+ * Drop support for Rails < 5, Ruby < 2.7.
8
18
 
9
19
  ## 2.5.1 (2024-08-14)
10
20
 
data/Gemfile.6.1.pg.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- active_type (2.6.0)
4
+ active_type (2.6.2)
5
5
  activerecord (>= 6.1)
6
6
 
7
7
  GEM
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- active_type (2.6.0)
4
+ active_type (2.6.2)
5
5
  activerecord (>= 6.1)
6
6
 
7
7
  GEM
data/Gemfile.7.1.pg.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- active_type (2.6.0)
4
+ active_type (2.6.2)
5
5
  activerecord (>= 6.1)
6
6
 
7
7
  GEM
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- active_type (2.6.0)
4
+ active_type (2.6.2)
5
5
  activerecord (>= 6.1)
6
6
 
7
7
  GEM
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- active_type (2.6.0)
4
+ active_type (2.6.2)
5
5
  activerecord (>= 6.1)
6
6
 
7
7
  GEM
@@ -70,4 +70,4 @@ DEPENDENCIES
70
70
  rspec (~> 3.4)
71
71
 
72
72
  BUNDLED WITH
73
- 2.6.1
73
+ 2.6.2
data/Gemfile.7.2.pg.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- active_type (2.6.0)
4
+ active_type (2.6.2)
5
5
  activerecord (>= 6.1)
6
6
 
7
7
  GEM
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- active_type (2.6.0)
4
+ active_type (2.6.2)
5
5
  activerecord (>= 6.1)
6
6
 
7
7
  GEM
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- active_type (2.6.0)
4
+ active_type (2.6.2)
5
5
  activerecord (>= 6.1)
6
6
 
7
7
  GEM
@@ -81,4 +81,4 @@ DEPENDENCIES
81
81
  sqlite3
82
82
 
83
83
  BUNDLED WITH
84
- 2.6.1
84
+ 2.6.2
@@ -124,6 +124,10 @@ module ActiveType
124
124
  @schema_cache = DummySchemaCache.new
125
125
  end
126
126
 
127
+ def self.quote_column_name(column_name)
128
+ column_name.to_s
129
+ end
130
+
127
131
  end
128
132
 
129
133
  module ClassMethods
@@ -1,3 +1,3 @@
1
1
  module ActiveType
2
- VERSION = '2.6.0'
2
+ VERSION = '2.6.2'
3
3
  end
@@ -239,6 +239,15 @@ module ActiveType
239
239
  super.merge(changes)
240
240
  end
241
241
 
242
+ def attribute_changed?(attr, **)
243
+ attr = attr.to_s
244
+ if virtual_attributes.key?(attr)
245
+ virtual_attributes_were[attr] != send(attr)
246
+ else
247
+ super
248
+ end
249
+ end
250
+
242
251
  if ActiveRecord::VERSION::MAJOR >= 4
243
252
  def changes_applied
244
253
  super
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: active_type
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.6.0
4
+ version: 2.6.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tobias Kraze
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2024-12-20 00:00:00.000000000 Z
12
+ date: 2025-02-12 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bundler
@@ -134,7 +134,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
134
134
  - !ruby/object:Gem::Version
135
135
  version: '0'
136
136
  requirements: []
137
- rubygems_version: 3.5.22
137
+ rubygems_version: 3.4.10
138
138
  signing_key:
139
139
  specification_version: 4
140
140
  summary: Make any Ruby object quack like ActiveRecord