@reminders.map(&:id)
app/controllers/reminders_controller.rb from authorNari's brushup - GitHub
@reminders.map(&:id)
動作 | ||
ruby 1.8.7 | irb | ○ |
ruby 1.8.6でRails 2.3.2 | script/console | ○ |
ruby 1.8.6 | irb | TypeError: wrong argument type Symbol (expected Proc) |
別の書き方では
@reminders.map {|reminder| reminder.id}