Re: [Rails] undefined method `name' for nil:NilClass

2015-06-29 Thread Colin Law
On 29 June 2015 at 18:54, William de Lima wrote: > .. > ActionView::Template::Error (undefined method `name' for nil:NilClass): > 9: .pull-right > 10: = submit_tag t('news.comment'), class: 'btn btn-primary' > 11: .clearfix > 12: - unless @item.comments.any? > 13: #comment-comp

[Rails] undefined method `name' for nil:NilClass

2015-06-29 Thread William de Lima
Hi, i'm pretty new to the Rail and Ruby and today I have a problem that I have to solve (tl;dr: the expert ruby/rails has left our company and now the newbies like me have to work on the projects that he left). So, let's go straight: I have an app running "normally", login function OK, but then