Created
May 24, 2012 13:31
-
-
Save kagemusha/2781562 to your computer and use it in GitHub Desktop.
TypeError: Cannot visit...(Rails)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Version: Rails 3.2.1 | |
TypeError: Cannot visit Videoset | |
Happens when specify class for id in validations (perhaps other places), e.g.: | |
INCORRECT | |
validates_uniqueness_of :song_num, :scope=>[:videoset] | |
CORRECT | |
validates_uniqueness_of :song_num, :scope=>[:videoset_id] | |
Would be nice if rails smart enough to take both |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment