This project is archived and is in readonly mode.

#2859 ✓resolved
Timur Vafin

[PATCH] Added AR:B#dup method for duplicationg object without frozen attributes

Reported by Timur Vafin | June 30th, 2009 @ 07:18 PM | in 2.x

Standard way to unfreeze object is to call dup method on it, but this does not working AR:B object, b/c in the ActiveRecord::Base methods #freeze and #frozen? overwritten for changing @attributes directly.

Here is simple patch with test for implementing #dup on AR:B.

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>

People watching this ticket

Attachments

Referenced by

Pages