Ruby on Rails Wednesday, March 2, 2016

Colin Law wrote in post #1181854:
> On 2 March 2016 at 22:06, David Williams <lists@ruby-forum.com> wrote:

> Just to point out that the fundamental mistake you made here was
> calling it @following_activities. If you had called it
> @following_posts or something similar then you would probably fnot
> have made the error.
> For the future simple debugging can be achieved by inserting logger
> output in the code at appropriate points, so for example if after the
> line
> <% @following_activities.each do |user| %>
> you insert the line
> logger.info "user = #{user.inspect}"
> then the debug would be inserted into log/development.log which would
> probably have enabled you to see the problem.
>
> Colin

Yes, it was a fatal flaw in my naming convention that led to the
confusion. Thank you.

--
Posted via http://www.ruby-forum.com/.

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/c63a9c31caba143e9487cf46270f3f1a%40ruby-forum.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment