module JamRuby
  class UserAuthorization < ActiveRecord::Base

    attr_accessible :provider, :uid, :token, :token_expiration

    self.table_name = "user_authorizations"

    self.primary_key = 'id'

    belongs_to :user, :class_name => "JamRuby::User", :foreign_key => "user_id"
    validates :provider, :uid, :presence => true

    # token and token_expiration can be missing
    
  end
end
