{"action":"created","issue":{"url":"https://api.github.com/repos/learn-co-curriculum/partial-locals-lab/issues/14","repository_url":"https://api.github.com/repos/learn-co-curriculum/partial-locals-lab","labels_url":"https://api.github.com/repos/learn-co-curriculum/partial-locals-lab/issues/14/labels{/name}","comments_url":"https://api.github.com/repos/learn-co-curriculum/partial-locals-lab/issues/14/comments","events_url":"https://api.github.com/repos/learn-co-curriculum/partial-locals-lab/issues/14/events","html_url":"https://github.com/learn-co-curriculum/partial-locals-lab/issues/14","id":316597694,"number":14,"title":"Unable to pass variable @students from classroom controller ","user":{"login":"KristenLeach","id":31492991,"avatar_url":"https://avatars3.githubusercontent.com/u/31492991?v=4","gravatar_id":"","url":"https://api.github.com/users/KristenLeach","html_url":"https://github.com/KristenLeach","followers_url":"https://api.github.com/users/KristenLeach/followers","following_url":"https://api.github.com/users/KristenLeach/following{/other_user}","gists_url":"https://api.github.com/users/KristenLeach/gists{/gist_id}","starred_url":"https://api.github.com/users/KristenLeach/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/KristenLeach/subscriptions","organizations_url":"https://api.github.com/users/KristenLeach/orgs","repos_url":"https://api.github.com/users/KristenLeach/repos","events_url":"https://api.github.com/users/KristenLeach/events{/privacy}","received_events_url":"https://api.github.com/users/KristenLeach/received_events","type":"User","site_admin":false},"labels":[{"id":590326057,"url":"https://api.github.com/repos/learn-co-curriculum/partial-locals-lab/labels/Test","name":"Test","color":"ffe47e","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-04-22T17:34:32Z","updated_at":"2018-04-22T17:35:38Z","closed_at":null,"author_association":"NONE","body":"For the classroom#show view using the student partial, I set up my classroom controller like so: \r\ndef show\r\n    @classroom = Classroom.find(params[:id])\r\n    @students = @classroom.students\r\nend \r\n\r\nI then iterated through @students and used each individual student in the student partial. While this works in my browser as expected, the tests failed and kept giving me an error that @students was nil. Testing it in pry and the console showed that @classroom.students gave me back a full list of students, and it showed all students in the browser. \r\n\r\nThe only way I could pass the tests was to use @classroom.students.each to iterate on the show page rather than passing the @students variable I created in the controller. A technical coach helped me figure out the problem and suggested that it could be something specific in the tests that is not allowing the use of a variable @students. "},"comment":{"url":"https://api.github.com/repos/learn-co-curriculum/partial-locals-lab/issues/comments/383398455","html_url":"https://github.com/learn-co-curriculum/partial-locals-lab/issues/14#issuecomment-383398455","issue_url":"https://api.github.com/repos/learn-co-curriculum/partial-locals-lab/issues/14","id":383398455,"user":{"login":"KristenLeach","id":31492991,"avatar_url":"https://avatars3.githubusercontent.com/u/31492991?v=4","gravatar_id":"","url":"https://api.github.com/users/KristenLeach","html_url":"https://github.com/KristenLeach","followers_url":"https://api.github.com/users/KristenLeach/followers","following_url":"https://api.github.com/users/KristenLeach/following{/other_user}","gists_url":"https://api.github.com/users/KristenLeach/gists{/gist_id}","starred_url":"https://api.github.com/users/KristenLeach/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/KristenLeach/subscriptions","organizations_url":"https://api.github.com/users/KristenLeach/orgs","repos_url":"https://api.github.com/users/KristenLeach/repos","events_url":"https://api.github.com/users/KristenLeach/events{/privacy}","received_events_url":"https://api.github.com/users/KristenLeach/received_events","type":"User","site_admin":false},"created_at":"2018-04-22T17:35:38Z","updated_at":"2018-04-22T17:35:38Z","author_association":"NONE","body":"I'm not sure why this comment keeps capitalizing @students, but it was not capitalized in my program. :-) "}}
{"actor":{"display_login":"KristenLeach"}}