Afficher un message
Vieux 27/05/2008, 13h40   #12
Dave Bass
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: A simple newbie question (arrays and strings)

koichirose wrote:
> It returns: hello.rb:7: undefined method `capitalize' for nil:NilClass
> (NoMethodError)


That error message means you're trying to call the capitalize method on
something that doesn't exist. I.e. xxx.capitalise where xxx evaluates to
nil. The class NilClass doesn't have a capitalize method. Your problem
is with xxx; trying "p"-ing it.





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

  Réponse avec citation
 
Page generated in 0,05221 seconds with 9 queries