Hi,
I have a question regarding rendering partials:
I have this controller called twitter
class TwitterController < ApplicationController
def index
@twitter_search = Twitter::Search.new('#rails')
end
end
In the twitter index views i render a partial:
<%= render :partial => "shared/twitterlist" %>
This work's fine for the Twitter index view, but when I call the
render partial from another view like dashboard/index like this:
<%= render :partial => "shared/twitterlist" %>
I get this error:
You have a nil object when you didn't expect it!
You might have expected an instance of Array.
The error occurred while evaluating nil.each
What am I doing wrong here?
Is it even possible to share data across the views like that?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---