app/models/motor/dashboard.rb in motor-admin-pz-0.4.22 vs app/models/motor/dashboard.rb in motor-admin-pz-0.4.26

- old
+ new

@@ -8,10 +8,15 @@ has_many :taggable_tags, as: :taggable, dependent: :destroy has_many :tags, through: :taggable_tags, class_name: 'Motor::Tag' attribute :preferences, default: -> { ActiveSupport::HashWithIndifferentAccess.new } - serialize :preferences, HashSerializer + + if Rails.version.to_f >= 7.1 + serialize :preferences, coder: HashSerializer + else + serialize :preferences, HashSerializer + end scope :active, -> { where(deleted_at: nil) } def queries Motor::Query.where(id: preferences[:layout].pluck(:query_id))