Skip to content

Instantly share code, notes, and snippets.

@oleander
Created March 6, 2011 22:26
Show Gist options
  • Save oleander/857790 to your computer and use it in GitHub Desktop.
Save oleander/857790 to your computer and use it in GitHub Desktop.
# Works
class NamedVoteHistoryList < ActiveRecord::Base
belongs_to :user
belongs_to :vote_history_list
validates_presence_of :name
# validates :vote_history_list_id, :user_uniqueness => true <= This is the line
def url
#
end
def url=(url)
#
end
end
# Does not work
class NamedVoteHistoryList < ActiveRecord::Base
belongs_to :user
belongs_to :vote_history_list
validates_presence_of :name
validates :vote_history_list_id, :user_uniqueness => true
def url
#
end
def url=(url)
#
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment