Skip to content

Commit

Permalink
3.0: Gotta use Structs
Browse files Browse the repository at this point in the history
  • Loading branch information
kaspth committed Dec 18, 2023
1 parent 8f49c32 commit 628c755
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions test/boot/associated_object.rb
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,9 @@ class ApplicationRecord::AssociatedObject < ActiveRecord::AssociatedObject; end
class Author::Archiver < ApplicationRecord::AssociatedObject
end

Author::Classified = Data.define(:author)
Author::Fortification = Data.define(:author)
# TODO: Replace with Data.define once on Ruby 3.2.
Author::Classified = Struct.new(:author)
Author::Fortification = Struct.new(:author)

class Post::Publisher < ApplicationRecord::AssociatedObject
mattr_accessor :performed, default: false
Expand Down

0 comments on commit 628c755

Please sign in to comment.