Sha256: fd7c7c2b1b0d2c236337d72ba0df2b1b72dbc61b64842ed18f0562f2ff0ce73f
Contents?: true
Size: 465 Bytes
Versions: 3
Compression:
Stored size: 465 Bytes
Contents
module Models::Core class Domain < ActiveRecord::Base self.table_name = :restpack_core_domains attr_accessible :identifier, :application_id, :is_verified, :session_secret, :oauth_providers validates_presence_of :identifier, :application_id validates :identifier, :length => { :maximum => 512 } belongs_to :application before_save -> { self.oauth_providers ||= [] self.session_secret ||= SecureRandom.hex(16) } end end
Version data entries
3 entries across 3 versions & 1 rubygems