Re: [Rails-core] ActiveResource::Base#dup should take standard new/create args

2012-07-10 Thread Kurt Werle
On Monday, July 9, 2012 12:10:07 PM UTC-7, Nicolás Sanguinetti wrote: dup doesn't take arguments because in ruby dup doesn't take arguments. It wouldn't make sense to break the semantics of ruby just for this, IMO. I had not considered that. On the other hand: * it's not like dup calls

[Rails-core] ActiveResource::Base#dup should take standard new/create args

2012-07-09 Thread Kurt Werle
dup takes no args create and new both take the same args, and create can take a block It seems to me it would be more consistent (and convenient) if I could do some_record.dup(attributes_i_want_to_change) do |dup_record| dup_record.attribute = some_value