Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

This project is archived and is in readonly mode.

Scaffolding Cleanup

#1840

We should clean up two things in scaffolding that are a source of confusion to new developers (as measured by questions via IRC and elsewhere):

1) The index action in the controller should use .all instead of .find(:all)

2) The index view should use +@entities.each do |entity|+ instead of +for entity in @entities+.

Reported by CancelProfileIsBroken · February 1st, 2009 @ 04:49 PM

State: committed
Milestone: 2.x
Assigned to: Pratik Pratik
Importance: none

Activity

  1. Repository
    Repository
    • State changed from new to committed

    (from [44f02de2ad6d22d0d781c0c7303bcd8162aaa5d6]) Update scaffolding [#1840 state:committed]

    Signed-off-by: David Heinemeier Hansson david@loudthinking.com http://github.com/rails/rails/co...

    February 5th, 2009 @ 07:38 PM

  2. Mislav
  3. CancelProfileIsBroken
    CancelProfileIsBroken

    Because using "for" has been one of the perennial confusion points for people using Rails as an intro to Ruby. Have run into too many people who don't grok .each do because scaffolding & AWDWR taught them for first.

    February 5th, 2009 @ 10:14 PM