From: Gennady Bystritsky Date: 2006-05-11T04:09:20+09:00 Subject: Re: changing the type of a variable You may need to restart your Rails application so that your changes may be picked up. Gennady. > -----Original Message----- > From: list-bounce@example.com > [mailto:list-bounce@example.com] On Behalf Of Allison Newman > Sent: Wednesday, May 10, 2006 12:03 > To: ruby-talk ML > Subject: changing the type of a variable > > Hi, > > I'm a ruby newbie, although I'm a programmer with 10yrs > experience. I > was running myself through the tutorial in Agile Web Development With > Rails, when I ran into a problem. somewhere in the code I mistakenly > entered > > @items = 0 > > instead of > > @items = [] > > A bit later I tried the following > > @items << LineItem.for_product(product) > > but when i try to execute this code I got the following error: > > "cannot convert LineItem to Integer" > > Looking back through the code, I found the error mentioned above, and > corrected it. However, Rails still insists that @items is an > Integer. > Can anyone suggest what has gone wrong, or what I can do to fix it? > > Alli > > -- > Posted via http://www.ruby-forum.com/. > >