i am getting this same exact error message when i try to do a
User.find_by_username('array'). Im have twitter users signed up on my
site and i am trying to find the the users on my site from a
timeline.
When i try <%= User.find_by_username('status.user.screen_name') %> It
returns nil, but if i use <%= status.user.screen_name %> it returns
all the user screen names so i can not figure out what is going wrong.
On Mar 18, 3:45 am, Michael Pavling <pavl...@gmail.com> wrote:
> On 18 March 2010 06:18, Me <chabg...@gmail.com> wrote:
>
> > I assign an array to a hash value.
>
> > h[:ext_array] it is nil.
>
> I copied your hash into IRB and it worked fine:>> h = {:has_key=>0, :ext_array=>["Text file (.txt)<br/>", "Rich Text Format
>
> (.rtf)<br/>", "Word Document (.doc, .docx)<br/>"]}
> => {:has_key=>0, :ext_array=>["Text file (.txt)<br/>", "Rich Text
> Format\n(.rtf)<br/>", "Word Document (.doc, .docx)<br/>"]}>> h[:ext_array]
>
> => ["Text file (.txt)<br/>", "Rich Text Format\n(.rtf)<br/>", "Word
> Document (.doc, .docx)<br/>"]
>
>
>
> Can you post the code where you're accessing h[:ext_array] and getting
> nil. I think you might be getting nil as the result of an expression
> rather than the value from the hash.
--
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 rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
No comments:
Post a Comment