Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialMarcus Baron
38 PointsI've added all the code up until the very last step in the video, whereupon i get error : undefined method "pictures"
How do i fix this?
John Whittenburg
2,341 PointsFrom what you've explained, I would make sure that you have actually defined the method "pictures" properly in your code. Make sure it's not a typo. If all is well then make sure what you're passing to it is properly done. Also, when you read the error message, it should tell you where the problem is (what line it's on) in your code and will help narrow it down for you. Sorry if this doesn't help, but without seeing your code it could be a number of things and I won't be able to pin point it for you.
1 Answer
Brandon Barrette
20,485 PointsSounds like to me there is a missing
has_many :pictures
in the album model.
Also to note that this course is NOT rails 4 compatible and you will run into some errors because things change more quickly than videos can be made. The ideas behind these features can easily be integrated into any rails app though.
Robert Skoubo
6,854 PointsRobert Skoubo
6,854 PointsCan you add your code so that it can be viewed by others. That will allow others to better assist you with the problem.
Bob