So, I have that lovely NoMethodError listed in 8.3 (pg105 in book)…the problem is it’s not resolved by the books instructions (they’re the same as the pdf).
restarting server doesn’t fix it, hosing cookies doesn’t fix it, clearing the sessions db doesn’t fix it. I’m at a loss for what the problem is. My code is the same as the demo code (I’ve gone through line by line and even c&p’d).
ruby 1.8.7p72 rails 2.3.2 mysql 5.1.3
NoMethodError in Store#add_to_cart Showing app/views/store/add_to_cart.html.erb where line #4 raised: undefined method `quantity' for #<Product:0x4cfe410> Extracted source (around line #4): 1: <h2>Your Pragmatic Cart</h2> 2: <ul> 3: <% for item in @cart.items %> 4: <li><%= item.quantity %> × <%=h item.title %></li> 5: <% end %> 6: </ul>