user_agent_detail.rb 289 Bytes
Newer Older
1 2
# frozen_string_literal: true

3
class UserAgentDetail < ActiveRecord::Base
4
  belongs_to :subject, polymorphic: true # rubocop:disable Cop/PolymorphicAssociations
5

6
  validates :user_agent, :ip_address, :subject_id, :subject_type, presence: true
7 8

  def submittable?
9
    !submitted?
10 11
  end
end